1 个不稳定版本
0.1.0 | 2021 年 6 月 28 日 |
---|
#10 in #st
每月下载 43 次
69KB
868 行
Rust 版本的 usaddress
安装
cargo install usaddress
或
[dependencies]
usaddress = "0.1"
包含一个可以标记地址的二进制文件
usaddress "170th St and Broadway Ave New York, NY 10033"
<AddressString><AddressNumber>170th</AddressNumber><StreetName>St</StreetName><StreetName>and</StreetName><StreetName>Broadway</StreetName><StreetNamePostType>Ave</StreetNamePostType><PlaceName>New</PlaceName><PlaceName>York,</PlaceName><StateName>NY</StateName><ZipCode>10033</ZipCode></AddressString>
或库的使用
match usaddress::parse("170th St and Broadway Ave New York, NY 10033") {
Ok(tagged_addresses) => {
...
},
Err(e) => {
...
}
}
依赖关系
~3–4.5MB
~74K SLoC