Enum rtdlib::types::UserType[][src]

pub enum UserType {
    Bot(UserTypeBot),
    Deleted(UserTypeDeleted),
    Regular(UserTypeRegular),
    Unknown(UserTypeUnknown),
    // some variants omitted
}
Expand description

Represents the type of the user. The following types are possible: regular users, deleted users and bots

Variants

Bot

A bot (see https://core.telegram.org/bots)

Tuple Fields of Bot

0: UserTypeBot
Deleted

A deleted user or deleted bot. No information on the user besides the user_id is available. It is not possible to perform any active actions on this type of user

Tuple Fields of Deleted

0: UserTypeDeleted
Regular

A regular user

Tuple Fields of Regular

0: UserTypeRegular
Unknown

No information on the user besides the user_id is available, yet this user has not been deleted. This object is extremely rare and must be handled like a deleted user. It is not possible to perform any actions on users of this type

Tuple Fields of Unknown

0: UserTypeUnknown

Implementations

Trait Implementations

Performs the conversion.

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

Deserialize this value from the given Serde deserializer. Read more

Return td type to json string

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.