Struct tbot::state::messages::MessageId[][src]

#[must_use]
pub struct MessageId { pub chat_id: Id, pub message_id: Id, }

A struct containing a message’s and its chat’s IDs.

Fields

chat_id: Id

The ID of the message’s chat.

message_id: Id

The ID of the message.

Implementations

impl MessageId[src]

pub fn from_context<C>(context: &C) -> Self where
    C: Message
[src]

Constructs a MessageId from the provided context.

pub const fn from_message(message: &Message) -> Self[src]

Constructs a MessageId from the provided message.

Trait Implementations

impl Clone for MessageId[src]

impl Debug for MessageId[src]

impl<'de> Deserialize<'de> for MessageId[src]

impl Hash for MessageId[src]

impl<S> Index<MessageId> for Messages<S>[src]

type Output = S

The returned type after indexing.

impl PartialEq<MessageId> for MessageId[src]

impl Serialize for MessageId[src]

impl Copy for MessageId[src]

impl Eq for MessageId[src]

impl StructuralEq for MessageId[src]

impl StructuralPartialEq for MessageId[src]

Auto Trait Implementations

impl RefUnwindSafe for MessageId

impl Send for MessageId

impl Sync for MessageId

impl Unpin for MessageId

impl UnwindSafe for MessageId

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]