Enum quick_xml::Error[][src]

pub enum Error {
Show 13 variants Io(Error), Utf8(Utf8Error), UnexpectedEof(String), EndEventMismatch { expected: String, found: String, }, UnexpectedToken(String), UnexpectedBang, TextNotFound, XmlDeclWithoutVersion(Option<String>), NameWithQuote(usize), NoEqAfterName(usize), UnquotedValue(usize), DuplicatedAttribute(usizeusize), EscapeError(EscapeError),
}
Expand description

The error type used by this crate.

Variants

Io(Error)

Tuple Fields

0: Error

IO error

Utf8(Utf8Error)

Tuple Fields

Utf8 error

UnexpectedEof(String)

Tuple Fields

0: String

Unexpected End of File

EndEventMismatch

Fields

expected: String

Expected end event

found: String

Found end event

End event mismatch

UnexpectedToken(String)

Tuple Fields

0: String

Unexpected token

UnexpectedBang

Unexpected <!>

TextNotFound

Text not found, expected Event::Text

XmlDeclWithoutVersion(Option<String>)

Tuple Fields

Event::XmlDecl must start with version attribute

NameWithQuote(usize)

Tuple Fields

0: usize

Attribute Name contains quote

NoEqAfterName(usize)

Tuple Fields

0: usize

Attribute key not followed by with =

UnquotedValue(usize)

Tuple Fields

0: usize

Attribute value not quoted

DuplicatedAttribute(usizeusize)

Tuple Fields

0: usize
1: usize

Duplicate attribute

EscapeError(EscapeError)

Tuple Fields

0: EscapeError

Escape error

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

Creates a new Error::Io from the given error

Creates a new Error::Utf8 from the given error

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.