53 stable releases
Uses old Rust 2015
2.36.0 | Aug 6, 2024 |
---|---|
2.35.0 | Feb 17, 2024 |
2.34.0 | Jan 31, 2024 |
2.33.0 | Sep 6, 2023 |
0.2.0 | Feb 21, 2017 |
#583 in Data structures
754 downloads per month
47KB
1.5K
SLoC
tld
Top Level domain static hash map, tld list is obtained from of iana.org
extern crate tld;
assert!(tld::exist("com"));
assert!(tld::exist("io"));
assert!(tld::exist("lt"));
assert!(tld::exist("ru"));
assert!(tld::exist("de"));
assert!(!tld::exist(""));
assert!(!tld::exist("moc"));
assert!(tld::TLD.len() > 1400);
lib.rs
:
TLD - top level domain static map, list is obtained from iana.org.
Crate provides a way to verify top level domain existence.
extern crate tld;
assert!(tld::exist("com"));
assert!(tld::exist("io"));
assert!(tld::exist("lt"));
assert!(tld::exist("ru"));
assert!(tld::exist("de"));
assert!(!tld::exist(""));
assert!(!tld::exist("moc"));
assert!(tld::TLD.len() > 1400);
Dependencies
~135KB