[][src]Struct tbot::types::message::Message

#[non_exhaustive]pub struct Message {
    pub id: Id,
    pub from: Option<From>,
    pub date: i64,
    pub chat: Chat,
    pub forward: Option<Forward>,
    pub reply_to: Option<Box<Message>>,
    pub edit_date: Option<i64>,
    pub author_signature: Option<String>,
    pub reply_markup: Option<Keyboard>,
    pub kind: Kind,
    pub via_bot: Option<User>,
}

Represents a message.

Fields (Non-exhaustive)

Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.
id: Id

The ID of the message.

from: Option<From>

The author of the message. Note that this field is None for messages from channels.

date: i64

The timestamp of the message.

chat: Chat

The chat to which the message was sent.

forward: Option<Forward>

If this message is a forward, information about the original message.

reply_to: Option<Box<Message>>

If Some, the message that this message replies to.

edit_date: Option<i64>

If the message was edited, the date of last edit.

author_signature: Option<String>

The author's signature, if enabled for the channel.

reply_markup: Option<Keyboard>

The inline keyboard attached to the message.

kind: Kind

The kind of the message.

via_bot: Option<User>

The bot via which the message was sent.

Trait Implementations

impl Clone for Message[src]

impl Debug for Message[src]

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

impl PartialEq<Message> for Message[src]

impl StructuralPartialEq for Message[src]

Auto Trait Implementations

impl RefUnwindSafe for Message

impl Send for Message

impl Sync for Message

impl Unpin for Message

impl UnwindSafe for Message

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> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

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

impl<T> Instrument for T[src]

impl<T> Instrument for T[src]

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

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> WithSubscriber for T[src]