pub struct PeerRef {
pub id: PeerId,
pub auth: PeerAuth,
}Expand description
Ocap-style reference to a peer object, a peer object capability, bundling the identity
of a peer (its PeerId) with authority over it (as PeerAuth), to allow fluent use.
This type implements conversion to tl::enums::InputPeer and derivatives.
Fields§
§id: PeerIdThe peer identity.
auth: PeerAuthThe authority bound to both the sibling identity and the session of the logged-in user.
Trait Implementations§
Source§impl From<ChannelForbidden> for PeerRef
impl From<ChannelForbidden> for PeerRef
Source§fn from(channel: ChannelForbidden) -> Self
fn from(channel: ChannelForbidden) -> Self
Converts to this type from the input type.
Source§impl From<ChatForbidden> for PeerRef
impl From<ChatForbidden> for PeerRef
Source§fn from(chat: ChatForbidden) -> Self
fn from(chat: ChatForbidden) -> Self
Converts to this type from the input type.
Source§impl From<InputPeerChannel> for PeerRef
impl From<InputPeerChannel> for PeerRef
Source§fn from(channel: InputPeerChannel) -> Self
fn from(channel: InputPeerChannel) -> Self
Converts to this type from the input type.
Source§impl From<InputPeerChannelFromMessage> for PeerRef
impl From<InputPeerChannelFromMessage> for PeerRef
Source§fn from(channel: InputPeerChannelFromMessage) -> Self
fn from(channel: InputPeerChannelFromMessage) -> Self
Converts to this type from the input type.
Source§impl From<InputPeerChat> for PeerRef
impl From<InputPeerChat> for PeerRef
Source§fn from(chat: InputPeerChat) -> Self
fn from(chat: InputPeerChat) -> Self
Converts to this type from the input type.
Source§impl From<InputPeerSelf> for PeerRef
impl From<InputPeerSelf> for PeerRef
Source§fn from(_: InputPeerSelf) -> Self
fn from(_: InputPeerSelf) -> Self
Converts to this type from the input type.
Source§impl From<InputPeerUser> for PeerRef
impl From<InputPeerUser> for PeerRef
Source§fn from(user: InputPeerUser) -> Self
fn from(user: InputPeerUser) -> Self
Converts to this type from the input type.
Source§impl From<InputPeerUserFromMessage> for PeerRef
impl From<InputPeerUserFromMessage> for PeerRef
Source§fn from(user: InputPeerUserFromMessage) -> Self
fn from(user: InputPeerUserFromMessage) -> Self
Converts to this type from the input type.
Source§impl From<PeerRef> for InputChannel
impl From<PeerRef> for InputChannel
impl Copy for PeerRef
impl Eq for PeerRef
impl StructuralPartialEq for PeerRef
Auto Trait Implementations§
impl Freeze for PeerRef
impl RefUnwindSafe for PeerRef
impl Send for PeerRef
impl Sync for PeerRef
impl Unpin for PeerRef
impl UnwindSafe for PeerRef
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