pub enum SessionRole {
ClientOnly,
ServerOnly,
Both,
}Expand description
Which roles the session composes.
Chosen at EndpointSession::new time (or via the endpoint builders’
role() setter) and fixed for the session lifetime. Determines which
role handles exist after start:
ClientOnly:client()isSome,server()isNone. Inbound requests are counted (no_server_role) and their one-use reply sender released without sending.ServerOnly:server()isSome,client()isNone. Terminal responses with no consumer release their exact lease and countno_client_role.Both: both handles are present above the one shared coordinator.
Variants§
ClientOnly
Client requester only.
ServerOnly
Server responder + notification pool only.
Both
Both sibling roles above one ingress/coordinator.
Trait Implementations§
Source§impl Clone for SessionRole
impl Clone for SessionRole
impl Copy for SessionRole
Source§impl Debug for SessionRole
impl Debug for SessionRole
impl Eq for SessionRole
Source§impl PartialEq for SessionRole
impl PartialEq for SessionRole
impl StructuralPartialEq for SessionRole
Auto Trait Implementations§
impl Freeze for SessionRole
impl RefUnwindSafe for SessionRole
impl Send for SessionRole
impl Sync for SessionRole
impl Unpin for SessionRole
impl UnsafeUnpin for SessionRole
impl UnwindSafe for SessionRole
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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