simple_xml/error.rs
1#[derive(Debug)]
2pub enum Error {
3 IOError(std::io::Error),
4 ParseError(ParseError, usize),
5 ContentOutsideRoot,
6 TagNotFound(String, String),
7 AttributeNotFound(String, String),
8}
9
10#[derive(Debug)]
11pub enum ParseError {
12 MissingClosingTag(String),
13 MissingClosingDelimiter,
14 MissingAttributeValue(String),
15 MissingQuotes(String),
16}
17
18impl From<std::io::Error> for Error {
19 fn from(e: std::io::Error) -> Self {
20 Error::IOError(e)
21 }
22}