public final class IKSegmenter extends Object
| 构造器和说明 |
|---|
IKSegmenter(Reader input,
boolean useSmart)
IK分词器构造函数
|
IKSegmenter(Reader input,
Configuration cfg)
IK分词器构造函数
|
public IKSegmenter(Reader input, boolean useSmart)
input - useSmart - 为true,使用智能分词策略
非智能分词:细粒度输出所有可能的切分结果
智能分词: 合并数词和量词,对分词结果进行歧义判断public IKSegmenter(Reader input, Configuration cfg)
input - cfg - 使用自定义的Configuration构造分词器public Lexeme next() throws IOException
IOExceptionpublic void reset(Reader input)
input - Copyright © 2016. All rights reserved.