https://github.com/renfei/sogouscelfileprocessing
搜狗输入法词库 Scel 文件转换为 txt 文件的 Java 处理实现。
https://github.com/renfei/sogouscelfileprocessing
Last synced: 6 months ago
JSON representation
搜狗输入法词库 Scel 文件转换为 txt 文件的 Java 处理实现。
- Host: GitHub
- URL: https://github.com/renfei/sogouscelfileprocessing
- Owner: renfei
- Created: 2022-05-06T06:21:53.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2022-05-07T06:23:33.000Z (about 3 years ago)
- Last Synced: 2024-12-17T09:07:50.693Z (6 months ago)
- Language: Java
- Size: 535 KB
- Stars: 4
- Watchers: 1
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# SogouScelFileProcessing
搜狗输入法词库 Scel 文件转换为 txt 文件的 Java 处理实现。
## 现有词库
我也准备好了现成的词典库:[https://github.com/renfei/dict](https://github.com/renfei/dict)
## 使用示例
Scel 文件在我本机的路径是 ```/Users/renfei/Downloads/财会词汇大全.scel``` 将其转换到 ```/Users/renfei/Downloads/财会词汇大全.txt``` :```java
FileProcessing scel = new SogouScelFileProcessing();
scel.parseFile(Objects.requireNonNull("/Users/renfei/Downloads/财会词汇大全.scel", "/Users/renfei/Downloads/财会词汇大全.txt", true);
```将文件夹下所有 Scel 文件转到同一个 txt 文件:
```java
FileProcessing scel = new SogouScelFileProcessing();
scel.parseFiles("/Users/renfei/Downloads", "/Users/renfei/Downloads/txt/汇总.txt", false);
```将文件夹下所有 Scel 文件转到各自的 txt 文件:
```java
FileProcessing scel = new SogouScelFileProcessing();
scel.setTargetDir("/Users/renfei/Downloads/多对多");
scel.parseFile("/Users/renfei/Downloads", false);
```