use-host
use-host provides lightweight helpers for parsing hosts such as localhost, IP literals, and domain-style host names.
Experimental: this crate is below 0.3.0 and the API may change.
Example Usage
use ;
let host = parse_host.unwrap;
assert_eq!;
assert_eq!;
assert_eq!;
Scope
- Localhost, IP-literal, and hostname-style host detection.
- Simple host normalization and IPv6 bracket helpers.
Non-goals
- DNS lookup.
- Public suffix validation.
- Host reachability testing.
License
Licensed under MIT OR Apache-2.0.