pub struct PipeId { /* private fields */ }Expand description
Identifies one Pipe as its origin Relay session plus a session-local counter.
connection_id is monotonic only within its origin session. Combining
it with the cluster-unique session incarnation makes the PipeId globally
unique without exposing a Gateway identifier to the SDK wire contract.
Implementations§
Source§impl PipeId
impl PipeId
Sourcepub const fn new(origin_session_id: SessionId, connection_id: u64) -> Self
pub const fn new(origin_session_id: SessionId, connection_id: u64) -> Self
Creates an identifier from its origin session and connection counter.
Sourcepub const fn origin_session_id(self) -> SessionId
pub const fn origin_session_id(self) -> SessionId
Returns the session incarnation that originated the dial.
Sourcepub const fn connection_id(self) -> u64
pub const fn connection_id(self) -> u64
Returns the counter the origin session assigned to the dial.
Trait Implementations§
impl Copy for PipeId
impl Eq for PipeId
impl StructuralPartialEq for PipeId
Auto Trait Implementations§
impl Freeze for PipeId
impl RefUnwindSafe for PipeId
impl Send for PipeId
impl Sync for PipeId
impl Unpin for PipeId
impl UnsafeUnpin for PipeId
impl UnwindSafe for PipeId
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