com.hankcs.hanlp.dictionary.stopword
类 CoreStopWordDictionary

java.lang.Object
  继承者 com.hankcs.hanlp.dictionary.stopword.CoreStopWordDictionary

public class CoreStopWordDictionary
extends Object

核心停用词词典

作者:
hankcs

字段摘要
static Filter FILTER
          核心停用词典的核心过滤器
 
构造方法摘要
CoreStopWordDictionary()
           
 
方法摘要
static boolean add(String stopWord)
          加入停用词到停用词词典中
static void apply(List<Term> termList)
          对分词结果应用过滤
static boolean contains(String key)
           
static boolean remove(String stopWord)
          从停用词词典中删除停用词
static boolean shouldInclude(Term term)
          是否应当将这个term纳入计算,词性属于名词、动词、副词、形容词,并且不在停用词表中
static boolean shouldRemove(Term term)
          是否应当去掉这个词
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

字段详细信息

FILTER

public static Filter FILTER
核心停用词典的核心过滤器

构造方法详细信息

CoreStopWordDictionary

public CoreStopWordDictionary()
方法详细信息

contains

public static boolean contains(String key)

shouldInclude

public static boolean shouldInclude(Term term)
是否应当将这个term纳入计算,词性属于名词、动词、副词、形容词,并且不在停用词表中

参数:
term -
返回:
是否应当

shouldRemove

public static boolean shouldRemove(Term term)
是否应当去掉这个词

参数:
term - 词
返回:
是否应当去掉

add

public static boolean add(String stopWord)
加入停用词到停用词词典中

参数:
stopWord - 停用词
返回:
词典是否发生了改变

remove

public static boolean remove(String stopWord)
从停用词词典中删除停用词

参数:
stopWord - 停用词
返回:
词典是否发生了改变

apply

public static void apply(List<Term> termList)
对分词结果应用过滤

参数:
termList -


Copyright © 2014–2015 码农场. All rights reserved.