Skip to main content

CallKeyError

Type Alias CallKeyError 

Source
pub type CallKeyError = OpaqueFieldError;
Expand description

The error validate_call_key returns. Kept as a name so code that only formats the error or reads OpaqueFieldError::field keeps compiling.

Aliased Type§

pub enum CallKeyError {
    Empty {
        field: &'static str,
    },
    TooLong {
        field: &'static str,
        length: usize,
    },
    InvalidCharacter {
        field: &'static str,
        index: usize,
    },
}

Variants§

§

Empty

The value was the empty string. An absent value is None, never "".

Fields

§field: &'static str
§

TooLong

The value was longer than OPAQUE_FIELD_MAX_LEN bytes.

Fields

§field: &'static str
§length: usize
§

InvalidCharacter

The byte at index is not printable, non-space ASCII.

Fields

§field: &'static str
§index: usize