Enum trust_dns_proto::error::ProtoErrorKind[][src]

pub enum ProtoErrorKind {
Show variants Busy, Canceled(Canceled), CharacterDataTooLong { max: usize, len: usize, }, LabelOverlapsWithOther { label: usize, other: usize, }, DnsKeyProtocolNot3(u8), DomainNameTooLong(usize), EdnsNameNotRoot(Name), IncorrectRDataLengthRead { read: usize, len: usize, }, LabelBytesTooLong(usize), PointerNotPriorToLabel { idx: usize, ptr: u16, }, MaxBufferSizeExceeded(usize), Message(&'static str), Msg(String), NoError, NotAllRecordsWritten { count: usize, }, RrsigsNotPresent { name: Name, record_type: RecordType, }, UnknownAlgorithmTypeValue(u8), UnknownDnsClassStr(String), UnknownDnsClassValue(u16), UnknownRecordTypeStr(String), UnknownRecordTypeValue(u16), UnrecognizedLabelCode(u8), UnrecognizedNsec3Flags(u8), Io(Error), Poisoned, Ring(Unspecified), SSL(SslErrorStack), Timer, Timeout, UrlParsing(ParseError), Utf8(Utf8Error), FromUtf8(FromUtf8Error), ParseInt(ParseIntError),
}
Expand description

The error kind for errors that get returned in the crate

Variants

Busy
Expand description

The underlying resource is too busy

This is a signal that an internal resource is too busy. The intended action should be tried again, ideally after waiting for a little while for the situation to improve. Alternatively, the action could be tried on another resource (for example, in a name server pool).

Canceled(Canceled)
Expand description

An error caused by a canceled future

CharacterDataTooLong
Expand description

Character data length exceeded the limit

Show fields

Fields of CharacterDataTooLong

max: usize
Expand description

Specified maximum

len: usize
Expand description

Actual length

LabelOverlapsWithOther
Expand description

Overlapping labels

Show fields

Fields of LabelOverlapsWithOther

label: usize
Expand description

Start of the label that is overlaps

other: usize
Expand description

Start of the other label

DnsKeyProtocolNot3(u8)
Expand description

DNS protocol version doesn’t have the expected version 3

DomainNameTooLong(usize)
Expand description

A domain name was too long

EdnsNameNotRoot(Name)
Expand description

EDNS resource record label is not the root label, although required

IncorrectRDataLengthRead
Expand description

The length of rdata read was not as expected

Show fields

Fields of IncorrectRDataLengthRead

read: usize
Expand description

The amount of read data

len: usize
Expand description

The expected length of the data

LabelBytesTooLong(usize)
Expand description

Label bytes exceeded the limit of 63

PointerNotPriorToLabel
Expand description

Label bytes exceeded the limit of 63

Show fields

Fields of PointerNotPriorToLabel

idx: usize
Expand description

index of the label containing this pointer

ptr: u16
Expand description

location to which the pointer is directing

MaxBufferSizeExceeded(usize)
Expand description

The maximum buffer size was exceeded

Message(&'static str)
Expand description

An error with an arbitrary message, referenced as &’static str

Msg(String)
Expand description

An error with an arbitrary message, stored as String

NoError
Expand description

No error was specified

NotAllRecordsWritten
Expand description

Not all records were able to be written

Show fields

Fields of NotAllRecordsWritten

count: usize
Expand description

Number of records that were written before the error

RrsigsNotPresent
Expand description

Missing rrsigs

Show fields

Fields of RrsigsNotPresent

name: Name
Expand description

The record set name

record_type: RecordType
Expand description

The record type

UnknownAlgorithmTypeValue(u8)
Expand description

An unknown algorithm type was found

UnknownDnsClassStr(String)
Expand description

An unknown dns class was found

UnknownDnsClassValue(u16)
Expand description

An unknown dns class value was found

UnknownRecordTypeStr(String)
Expand description

An unknown record type string was found

UnknownRecordTypeValue(u16)
Expand description

An unknown record type value was found

UnrecognizedLabelCode(u8)
Expand description

An unrecognized label code was found

UnrecognizedNsec3Flags(u8)
Expand description

Unrecognized nsec3 flags were found

Io(Error)
Expand description

An error got returned from IO

Poisoned
Expand description

Any sync poised error

Expand description

A ring error

Expand description

An ssl error

Timer
Expand description

A tokio timer error

Timeout
Expand description

A request timed out

UrlParsing(ParseError)
Expand description

An url parsing error

Utf8(Utf8Error)
Expand description

A utf8 parsing error

FromUtf8(FromUtf8Error)
Expand description

A utf8 parsing error

ParseInt(ParseIntError)
Expand description

An int parsing error

Trait Implementations

impl Clone for ProtoErrorKind[src]

fn clone(&self) -> Self[src]

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Debug for ProtoErrorKind[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl Display for ProtoErrorKind[src]

fn fmt(&self, __formatter: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl Error for ProtoErrorKind[src]

fn source(&self) -> Option<&(dyn Error + 'static)>[src]

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

fn backtrace(&self) -> Option<&Backtrace>[src]

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

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

fn description(&self) -> &str1.0.0[src]

👎 Deprecated since 1.42.0:

use the Display impl or to_string()

fn cause(&self) -> Option<&dyn Error>1.0.0[src]

👎 Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

impl From<Error> for ProtoErrorKind[src]

fn from(source: Error) -> Self[src]

Performs the conversion.

impl From<FromUtf8Error> for ProtoErrorKind[src]

fn from(source: FromUtf8Error) -> Self[src]

Performs the conversion.

impl From<ParseError> for ProtoErrorKind[src]

fn from(source: ParseError) -> Self[src]

Performs the conversion.

impl From<ParseIntError> for ProtoErrorKind[src]

fn from(source: ParseIntError) -> Self[src]

Performs the conversion.

impl From<ProtoErrorKind> for ProtoError[src]

fn from(kind: ProtoErrorKind) -> ProtoError[src]

Performs the conversion.

impl From<SslErrorStack> for ProtoErrorKind[src]

fn from(source: SslErrorStack) -> Self[src]

Performs the conversion.

impl From<Unspecified> for ProtoErrorKind[src]

fn from(source: Unspecified) -> Self[src]

Performs the conversion.

impl From<Utf8Error> for ProtoErrorKind[src]

fn from(source: Utf8Error) -> Self[src]

Performs the conversion.

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

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

pub fn from(t: T) -> T[src]

Performs the conversion.

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

pub fn into(self) -> U[src]

Performs the conversion.

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

pub fn to_owned(&self) -> T[src]

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

pub fn clone_into(&self, target: &mut T)[src]

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

recently added

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

impl<T> ToString for T where
    T: Display + ?Sized
[src]

pub default fn to_string(&self) -> String[src]

Converts the given value to a String. Read more

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.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

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.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 

pub fn vzip(self) -> V