资源简介

结巴分词用到的资源文件,使用方式见博客

资源截图

代码片段和文件信息

package com.huaban.analysis.jieba;

import java.util.regex.Pattern;


public class CharacterUtil {
    public static Pattern reSkip = Pattern.compile(“(\\d+\\.\\d+|[a-zA-Z0-9]+)“);
    private static final char[] connectors = new char[] { ‘+‘ ‘#‘ ‘&‘ ‘.‘ ‘_‘ ‘-‘ };


    public static boolean isChineseLetter(char ch) {
        if (ch >= 0x4E00 && ch <= 0x9FA5)
            return true;
        return false;
    }


    public static boolean isEnglishLetter(char ch) {
        if ((ch >= 0x0041 && ch <= 0x005A) || (ch >= 0x0061 && ch <= 0x007A))
            return true;
        return false;
    }


    public static boolean isDigit(char ch) {
        if (ch >= 0x0030 && ch <= 0x0039)
            return true;
        return false;
    }


    public static boolean isConnector(char ch) {

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件    5071839  2016-05-20 20:30  jieba分词\dict.txt

     文件       1717  2016-05-20 20:30  jieba分词\huaban\analysis\jieba\CharacterUtil.java

     文件       9981  2016-05-20 20:30  jieba分词\huaban\analysis\jieba\DictSegment.java

     文件       2735  2016-05-20 20:30  jieba分词\huaban\analysis\jieba\Hit.java

     文件       8023  2016-05-20 20:30  jieba分词\huaban\analysis\jieba\Jiebasegmenter.java

     文件        223  2016-05-20 20:30  jieba分词\huaban\analysis\jieba\Node.java

     文件        301  2016-05-20 20:30  jieba分词\huaban\analysis\jieba\Pair.java

     文件        446  2016-05-20 20:30  jieba分词\huaban\analysis\jieba\SegToken.java

     文件       8232  2016-05-20 20:30  jieba分词\huaban\analysis\jieba\viterbi\FinalSeg.java

     文件       6163  2016-05-20 20:30  jieba分词\huaban\analysis\jieba\WordDictionary.java

     文件      35530  2016-05-20 20:30  jieba分词\jieba.java.code.style.xml

     文件     665440  2016-05-20 20:30  jieba分词\prob_emit.txt

     目录          0  2016-11-16 20:29  jieba分词\huaban\analysis\jieba\viterbi

     目录          0  2016-11-16 20:29  jieba分词\huaban\analysis\jieba

     目录          0  2016-11-16 20:29  jieba分词\huaban\analysis

     目录          0  2016-11-16 20:29  jieba分词\huaban

     目录          0  2016-11-16 20:29  jieba分词

----------- ---------  ---------- -----  ----

              5810630                    17


评论

共有 条评论

相关资源