pub struct StreamSession<A>where
A: Agent,{ /* private fields */ }Implementations§
Methods from Deref<Target = AgentSession<A>>§
Methods from Deref<Target = Address<A>>§
pub fn send(&self, msg: impl MessageFor<A>) -> Result<(), Error>
Sourcepub async fn join(&mut self) -> Result<AgentStatus, Error>
pub async fn join(&mut self) -> Result<AgentStatus, Error>
Important! join must use a reference to allow using it under DerefMut trait
pub fn sender<M>(&self) -> Recipient<M>where
M: MessageFor<A>,
pub fn event<E>(&self, event: E) -> Result<(), Error>
pub fn event_tagged<E, T>(&self, event: E, tag: T) -> Result<(), Error>
pub fn recipient<E>(&self) -> Recipient<E>
pub fn recipient_tagged<E, T>(&self, tag: T) -> Recipient<E>
pub fn interrupt(&self) -> Result<(), Error>
Trait Implementations§
Source§impl<A> AgentContext<A> for StreamSession<A>where
A: Agent,
impl<A> AgentContext<A> for StreamSession<A>where
A: Agent,
fn session(&mut self) -> &mut AgentSession<A>
fn next_envelope<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Option<Box<dyn MessageFor<A>>>> + Send + 'async_trait>>where
'life0: 'async_trait,
StreamSession<A>: 'async_trait,
Source§impl<A> Default for StreamSession<A>where
A: Agent,
impl<A> Default for StreamSession<A>where
A: Agent,
Source§fn default() -> StreamSession<A>
fn default() -> StreamSession<A>
Returns the “default value” for a type. Read more
Source§impl<A> Deref for StreamSession<A>where
A: Agent,
impl<A> Deref for StreamSession<A>where
A: Agent,
Source§type Target = AgentSession<A>
type Target = AgentSession<A>
The resulting type after dereferencing.
Source§impl<A> DerefMut for StreamSession<A>where
A: Agent,
impl<A> DerefMut for StreamSession<A>where
A: Agent,
Source§impl<A> ManagedContext for StreamSession<A>where
A: Agent,
impl<A> ManagedContext for StreamSession<A>where
A: Agent,
Source§impl<A> ReachableContext for StreamSession<A>where
A: Agent,
impl<A> ReachableContext for StreamSession<A>where
A: Agent,
Source§fn address(&self) -> &<StreamSession<A> as ReachableContext>::Address
fn address(&self) -> &<StreamSession<A> as ReachableContext>::Address
A reference to an address.
Auto Trait Implementations§
impl<A> !Freeze for StreamSession<A>
impl<A> !RefUnwindSafe for StreamSession<A>
impl<A> Send for StreamSession<A>
impl<A> !Sync for StreamSession<A>
impl<A> Unpin for StreamSession<A>
impl<A> !UnwindSafe for StreamSession<A>
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