Struct ockam_core::Mailboxes
source · [−]pub struct Mailboxes { /* private fields */ }
Expand description
A collection of Mailbox
es for a [Context
]
Implementations
sourceimpl Mailboxes
impl Mailboxes
sourcepub fn new(main_mailbox: Mailbox, additional_mailboxes: Vec<Mailbox>) -> Self
pub fn new(main_mailbox: Mailbox, additional_mailboxes: Vec<Mailbox>) -> Self
Create a new collection of Mailboxes
from the given Mailbox
es
sourcepub fn main<A: Into<Address>>(
address: A,
access_control: Arc<dyn AccessControl>
) -> Self
pub fn main<A: Into<Address>>(
address: A,
access_control: Arc<dyn AccessControl>
) -> Self
Create a new collection of Mailboxes
for the given
Address
with the given AccessControl
sourcepub fn from_address_set(
address_set: AddressSet,
access_control: Arc<dyn AccessControl>
) -> Self
pub fn from_address_set(
address_set: AddressSet,
access_control: Arc<dyn AccessControl>
) -> Self
Create a new Mailboxes
from the given AddressSet
and AccessControl
Note that all Mailbox
es will use the same AccessControl.
sourcepub fn aliases(&self) -> AddressSet
pub fn aliases(&self) -> AddressSet
Return an AddressSet
containing all addresses represented by these Mailboxes
sourcepub fn main_address(&self) -> Address
pub fn main_address(&self) -> Address
Return the main Address
for these Mailboxes
sourcepub fn contains(&self, msg_addr: &Address) -> bool
pub fn contains(&self, msg_addr: &Address) -> bool
Return true
if the given Address
is represented by these Mailboxes
Return true
if the given Address
is authorized to post
the given LocalMessage
to these Mailboxes
sourcepub fn addresses(&self) -> AddressSet
pub fn addresses(&self) -> AddressSet
Return the AddressSet
represented by these Mailboxes
sourcepub fn main_mailbox(&self) -> &Mailbox
pub fn main_mailbox(&self) -> &Mailbox
Return a reference to the main Mailbox
for this collection
of Mailboxes
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Mailboxes
impl Send for Mailboxes
impl Sync for Mailboxes
impl Unpin for Mailboxes
impl !UnwindSafe for Mailboxes
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more