[−][src]Struct wascc_actor::CapabilitiesContext
The capabilities context is the gateway through which all actors communicate with a host runtime. A reference
to a capabilities context is passed to the receive function defined by the actor. Individual capabilities are separated
through function calls for each capability provider, including any bound opaque raw providers.
Methods
impl CapabilitiesContext[src]
pub fn new() -> CapabilitiesContext[src]
Creates a new capabilities context. This is invoked by the actor_receive macro
pub fn custom(
kv: impl KeyValueStore + 'static,
msg: impl MessageBroker + 'static,
raw: impl RawCapability + 'static,
blob: impl ObjectStore + 'static,
extras: impl Extras + 'static
) -> Self[src]
kv: impl KeyValueStore + 'static,
msg: impl MessageBroker + 'static,
raw: impl RawCapability + 'static,
blob: impl ObjectStore + 'static,
extras: impl Extras + 'static
) -> Self
Creates a custom capabilities context. This should be invoked by unit tests looking to test a receive function with mock capabilities
pub fn kv(&self) -> &dyn KeyValueStore[src]
pub fn msg(&self) -> &dyn MessageBroker[src]
pub fn raw(&self) -> &dyn RawCapability[src]
pub fn objectstore(&self) -> &dyn ObjectStore[src]
pub fn extras(&self) -> &dyn Extras[src]
pub fn log(&self, msg: &str)[src]
Trait Implementations
impl Default for CapabilitiesContext[src]
fn default() -> CapabilitiesContext[src]
Auto Trait Implementations
impl !RefUnwindSafe for CapabilitiesContext
impl !Send for CapabilitiesContext
impl !Sync for CapabilitiesContext
impl Unpin for CapabilitiesContext
impl !UnwindSafe for CapabilitiesContext
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,