7 releases (stable)

2.0.4 Nov 10, 2023
2.0.3 Oct 12, 2022
2.0.2 Sep 10, 2022
2.0.1 Aug 2, 2022
0.1.0 May 6, 2020

#64 in Internationalization (i18n)

Download history 1/week @ 2024-10-07 23/week @ 2024-10-14 21/week @ 2024-11-04 10/week @ 2024-11-18 35/week @ 2024-12-02 98/week @ 2024-12-09 44/week @ 2024-12-16 25/week @ 2024-12-23 15/week @ 2024-12-30 43/week @ 2025-01-06 30/week @ 2025-01-13 11/week @ 2025-01-20

102 downloads per month
Used in chinese_dictionary

MIT license

1.5MB
124 lines

chinese_detection

v2.0.0

About

Classify a string as either English, Chinese, or Pinyin.

Usage

extern crate chinese_detection;

use chinese_detection::{ClassificationResult, classify};

assert_eq!(ClassificationResult::EN, classify("test"));
assert_eq!(ClassificationResult::PY, classify("shiyan")); 
assert_eq!(ClassificationResult::ZH, classify("实验")); 

License

MIT


lib.rs:

About

Classify a string as either English, Chinese, or Pinyin.

Usage

extern crate chinese_detection;

use chinese_detection::{ClassificationResult, classify};

assert_eq!(ClassificationResult::EN, classify("test"));
assert_eq!(ClassificationResult::PY, classify("shiyan"));
assert_eq!(ClassificationResult::ZH, classify("实验"));

Dependencies