Enum telegram_bot::Error[][src]

pub enum Error {
    Http(Error),
    Io(Error),
    JsonDecode(DecoderError),
    JsonEncode(EncoderError),
    Api(String),
    InvalidState(String),
    InvalidTokenFormat(ParseError),
    InvalidEnvironmentVar(VarError),
    InvalidPath(String),
}

Telegram-Bot Error: Anything that may fail (HTTP, JSON, ...)

Variants

HTTP related error

IO related error (mainly reading the http result)

Error while decoding JSON data

Error while encoding JSON data

Telegram server reponsded with an error + description

This should never happen (it possibly could if the telegram servers would respond with garbage)

Occurs, if the given bot token would not result in a valid request URL.

The given environment variable could not be fetched.

The given path is not valid.

Trait Implementations

impl Debug for Error
[src]

Formats the value using the given formatter. Read more

impl Error for Error
[src]

This method is soft-deprecated. Read more

The lower-level cause of this error, if any. Read more

impl Display for Error
[src]

Formats the value using the given formatter. Read more

impl From<Error> for Error
[src]

Performs the conversion.

impl From<Error> for Error
[src]

Performs the conversion.

impl From<DecoderError> for Error
[src]

Performs the conversion.

impl From<EncoderError> for Error
[src]

Performs the conversion.

impl From<ParseError> for Error
[src]

Performs the conversion.

impl From<VarError> for Error
[src]

Performs the conversion.

Auto Trait Implementations

impl Send for Error

impl Sync for Error