Enum eccodes::errors::CodesError[][src]

pub enum CodesError {
    Internal(CodesInternal),
    LibcNonZero(i32Errno),
    FileHandlingInterrupted(Error),
    NoMessages,
    CstrUTF8(Utf8Error),
    NulChar(FromBytesWithNulError),
    MissingKey,
}
Expand description

Errors returned by the crate’s functions. These are the only errors that the user may face.

Variants

Internal(CodesInternal)

Returned when ecCodes library function returns an error code. Check CodesInternal for more details.

Tuple Fields of Internal

0: CodesInternal
LibcNonZero(i32Errno)

Returned when one of libc functions returns a non-zero error code. Check libc documentation for details of the errors. For libc reference check these websites: (1) (2)

Tuple Fields of LibcNonZero

0: i321: Errno
FileHandlingInterrupted(Error)

Returned when there is an issue while handlng the file. Check the std::fs documentation why and when this error can occur.

Tuple Fields of FileHandlingInterrupted

0: Error
NoMessages

Returned when the constructor did not find any message of requested kind

CstrUTF8(Utf8Error)

Returned when the string cannot be parsed as valid UTF8 string.

Tuple Fields of CstrUTF8

0: Utf8Error

Returned when the C-string returned by ecCodes library cannot be converted into a Rust-string.

Tuple Fields of NulChar

0: FromBytesWithNulError
MissingKey

Returned when the requested key is not present in the message. Similar to CodesInternal::CodesNotFound and CodesInternal::CodesMissingKey.

Trait Implementations

Formats the value using the given formatter. Read more

Formats the value using the given formatter. Read more

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

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

Returns a stack backtrace, if available, of where this error occurred. Read more

👎 Deprecated since 1.42.0:

use the Display impl or to_string()

👎 Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

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.

Converts the given value to a String. 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.