commit | 3404a63facd25a3684796d2ec9b860da317caf88 | [log] [tgz] |
---|---|---|
author | JinsukKim <jindor.code@gmail.com> | Tue Jan 08 22:36:59 2019 |
committer | GitHub <noreply@github.com> | Tue Jan 08 22:36:59 2019 |
tree | 844ffce1fe427b2425df367c9e562b313abd3ab4 | |
parent | 94c367a1fe3a13207f4b22604fcfd1d9f9ddf6d9 [diff] | |
parent | 5299bca7727cacad2955cd67fe913d9c44ce9694 [diff] |
Merge pull request #9 from Baklap4/fix/warnings Fixed warnings, removed unused variables / code
Compact Encoding Detection(CED for short) is a library written in C++ that scans given raw bytes and detect the most likely text encoding.
Basic usage:
#include "compact_enc_det/compact_enc_det.h" const char* text = "Input text"; bool is_reliable; int bytes_consumed; Encoding encoding = CompactEncDet::DetectEncoding( text, strlen(text), nullptr, nullptr, nullptr, UNKNOWN_ENCODING, UNKNOWN_LANGUAGE, CompactEncDet::WEB_CORPUS, false, &bytes_consumed, &is_reliable);
You need CMake to build the package. After unzipping the source code , run autogen.sh
to build everything automatically. The script also downloads Google Test framework needed to build the unittest.
$ cd compact_enc_det $ ./autogen.sh ... $ bin/ced_unittest
On Windows, run cmake .
to download the test framework, and generate project files for Visual Studio.
D:\packages\compact_enc_det> cmake .