9 个版本 (重大更新)
| 0.9.0 | 2019 年 3 月 3 日 |
|---|---|
| 0.8.0 | 2019 年 1 月 2 日 |
| 0.7.0 | 2018 年 2 月 7 日 |
| 0.6.0 | 2017 年 9 月 22 日 |
| 0.1.1 | 2017 年 6 月 20 日 |
#388 在 国际化 (i18n)
每月 474 次下载
用于 10 个软件包 (3 个直接使用)
12KB
185 行
UNIC — IDNA — Punycode (RFC 3492)
此 UNIC 组件实现了来自 Punycode: A Bootstring encoding of Unicode for Internationalized Domain Names in Applications (IDNA) 的算法。
注意
此组件的初始代码基于来自 rust-url 的 idna 软件包。
lib.rs:
UNIC — IDNA — Punycode (RFC 3492)
unic 的一部分:Rust 的 Unicode 和国际化软件包。
Punycode 算法 (RFC 3492) 实现。
由于 Punycode 基本上在 Unicode 代码点上工作,encode 和 decode 接受并返回 char 的切片和向量。 encode_str 和 decode_to_string 提供方便的包装器,将 Rust 的基于 UTF-8 的 str 和 String 类型转换为和从转换。