whoisthere

WHOIS parsing crate


Usage

```rust use whoisthere::parse_info;

let domainname: &str = "somesite.co.uk"; let whoisresponsefilepathstring: String = format!("tests/data/{}.txt", &domainname); let whoisresponsefilepath: &Path = Path::new(&whoisresponsefilepathstring); let whoisresponse: String = fs::readtostring(whoisresponsefilepath.asosstr()) .expect("Something went wrong reading the file"); let domainprops = parseinfo(domainname, &whois_response);

asserteq!(domainprops.domainname, "somesite.co.uk"); asserteq!(domainprops.expirationdate, "2022-05-14T00:00:00Z"); asserteq!(domainprops.isregistered, true); asserteq!(domainprops.isundergraceperiod, false); ```


License

To the extent possible under law, the author(s) have dedicated all copyright related and neighboring rights to this software to the public domain worldwide. This software is distributed without any warranty.