Struct whois_rust::WhoIs
source · pub struct WhoIs { /* private fields */ }
Expand description
The WhoIs
structure stores the list of WHOIS servers in-memory.
Implementations
sourceimpl WhoIs
impl WhoIs
sourcepub fn from_path<P: AsRef<Path>>(path: P) -> Result<WhoIs, WhoIsError>
pub fn from_path<P: AsRef<Path>>(path: P) -> Result<WhoIs, WhoIsError>
Read the list of WHOIS servers (JSON data) from a file to create a WhoIs
instance.
sourcepub fn from_string<S: AsRef<str>>(string: S) -> Result<WhoIs, WhoIsError>
pub fn from_string<S: AsRef<str>>(string: S) -> Result<WhoIs, WhoIsError>
Read the list of WHOIS servers (JSON data) from a string to create a WhoIs
instance.
sourcepub fn lookup(&self, options: WhoIsLookupOptions) -> Result<String, WhoIsError>
pub fn lookup(&self, options: WhoIsLookupOptions) -> Result<String, WhoIsError>
Lookup a domain or an IP.
Auto Trait Implementations
impl RefUnwindSafe for WhoIs
impl Send for WhoIs
impl Sync for WhoIs
impl Unpin for WhoIs
impl UnwindSafe for WhoIs
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more