Enum parse_hosts::DataParseError
[−]
[src]
pub enum DataParseError { NoInternalSpace, HostWasIp(Ipv4Addr), BadHost(char, String), BadIp(AddrParseError, String), }
Error parsing a line in /etc/hosts
.
Variants
NoInternalSpace
The line didn't have a space between the host and IP.
This includes any line that doesn't have an internal space; the host and IP are not actually checked.
HostWasIp(Ipv4Addr)
The given host was actually an IPv4 address.
BadHost(char, String)
The given host had an invalid character.
BadIp(AddrParseError, String)
The IP failed to parse.
Trait Implementations
impl Clone for DataParseError
[src]
fn clone(&self) -> DataParseError
[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 DataParseError
[src]
impl Eq for DataParseError
[src]
impl PartialEq for DataParseError
[src]
fn eq(&self, __arg_0: &DataParseError) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &DataParseError) -> bool
[src]
This method tests for !=
.
impl Error for DataParseError
[src]
fn description(&self) -> &str
[src]
A short description of the error. Read more
fn cause(&self) -> Option<&Error>
[src]
The lower-level cause of this error, if any. Read more