Enum saltyrtc_client::Role
source · [−]pub enum Role {
Initiator,
Responder,
}
Expand description
The role of a peer.
Variants
Initiator
A SaltyRTC compliant client who wants to establish a WebRTC or ORTC peer-to-peer connection to a responder.
Responder
A SaltyRTC compliant client who wants to establish a WebRTC or ORTC peer-to-peer connection to an initiator.
Implementations
sourceimpl Role
impl Role
sourcepub fn is_initiator(self) -> bool
pub fn is_initiator(self) -> bool
Return true if this role is the initiator.
sourcepub fn is_responder(self) -> bool
pub fn is_responder(self) -> bool
Return true if this role is the responder.
Trait Implementations
impl Copy for Role
impl Eq for Role
impl StructuralEq for Role
impl StructuralPartialEq for Role
Auto Trait Implementations
impl RefUnwindSafe for Role
impl Send for Role
impl Sync for Role
impl Unpin for Role
impl UnwindSafe for Role
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
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