Skip to content

Commit

Permalink
let user reset dict for support reinit dict .
Browse files Browse the repository at this point in the history
  • Loading branch information
tianchunfeng committed Dec 3, 2015
1 parent b1f74d9 commit c02c720
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/main/java/com/huaban/analysis/jieba/WordDictionary.java
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,15 @@ public void init(Path configFile) {
}
}
}


/**
* let user just use their own dict instead of the default dict
*/
public void resetDict(){
_dict = new DictSegment((char) 0);
freqs.clear();
}


public void loadDict() {
Expand Down

0 comments on commit c02c720

Please sign in to comment.