pub struct Layer1NetCollectionServer {
pub net_id: String,
pub namespace: MCardTokenNamespace,
pub adapter: MCardHostMountAdapter,
pub firings: BTreeMap<String, FiringReceiptMCard>,
}Expand description
Exposes a running Layer 1 Petri Net as a Collection Server under mcard://ns/<net_id>/ (INV-512-03, INV-517).
Fields§
§net_id: String§namespace: MCardTokenNamespace§adapter: MCardHostMountAdapter§firings: BTreeMap<String, FiringReceiptMCard>Implementations§
Source§impl Layer1NetCollectionServer
impl Layer1NetCollectionServer
pub fn new(net_id: &str) -> Self
pub fn with_namespace( net_id: &str, namespace: MCardTokenNamespace, adapter: Option<MCardHostMountAdapter>, ) -> Self
pub fn marking(&self) -> &MCardMarking
pub fn base_uri(&self) -> String
pub fn record_firing(&mut self, receipt: FiringReceiptMCard)
pub fn sync_to_collection( &mut self, _sponsor_did: Option<&str>, ) -> Result<(), String>
pub fn read_resource(&self, subpath: &str) -> Result<String, String>
pub fn list_resources(&self) -> Result<Vec<String>, String>
Auto Trait Implementations§
impl Forget for Layer1NetCollectionServer
impl Freeze for Layer1NetCollectionServer
impl RefUnwindSafe for Layer1NetCollectionServer
impl Send for Layer1NetCollectionServer
impl Sync for Layer1NetCollectionServer
impl Unpin for Layer1NetCollectionServer
impl UnsafeUnpin for Layer1NetCollectionServer
impl UnwindSafe for Layer1NetCollectionServer
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more