pub struct HostsFileLine { /* private fields */ }
Implementations§
Source§impl HostsFileLine
impl HostsFileLine
pub fn from_empty() -> HostsFileLine
pub fn from_comment(c: &str) -> HostsFileLine
pub fn from_string(line: &str) -> Result<HostsFileLine, ParseError>
pub fn ip(&self) -> Option<String>
pub fn hosts(&self) -> Vec<String>
pub fn comment(&self) -> Option<String>
pub fn has_host(&self) -> bool
pub fn has_comment(&self) -> bool
Trait Implementations§
Source§impl Debug for HostsFileLine
impl Debug for HostsFileLine
Source§impl Display for HostsFileLine
impl Display for HostsFileLine
Source§impl FromStr for HostsFileLine
impl FromStr for HostsFileLine
Source§impl PartialEq for HostsFileLine
impl PartialEq for HostsFileLine
impl Eq for HostsFileLine
impl StructuralPartialEq for HostsFileLine
Auto Trait Implementations§
impl Freeze for HostsFileLine
impl RefUnwindSafe for HostsFileLine
impl Send for HostsFileLine
impl Sync for HostsFileLine
impl Unpin for HostsFileLine
impl UnwindSafe for HostsFileLine
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more