private void init() {
if (chinesdJF == null) {
chinesdJF = CJFBeanFactory.getChineseJF();
}
if (seg == null) {
final ResourceDataBroker dataBroker = JLanguageTool.getDataBroker();
final InputStream coreDictIn = dataBroker.getFromResourceDirAsStream("/zh/coreDict.dct");
final InputStream bigramDictIn = dataBroker.getFromResourceDirAsStream("/zh/BigramDict.dct");
final InputStream personTaggerDctIn = dataBroker.getFromResourceDirAsStream("/zh/nr.dct");
final InputStream personTaggerCtxIn = dataBroker.getFromResourceDirAsStream("/zh/nr.ctx");
final InputStream transPersonTaggerDctIn = dataBroker.getFromResourceDirAsStream("/zh/tr.dct");
final InputStream transPersonTaggerCtxIn = dataBroker.getFromResourceDirAsStream("/zh/tr.ctx");
final InputStream placeTaggerDctIn = dataBroker.getFromResourceDirAsStream("/zh/ns.dct");
final InputStream placeTaggerCtxIn = dataBroker.getFromResourceDirAsStream("/zh/ns.ctx");
final InputStream lexTaggerCtxIn = dataBroker.getFromResourceDirAsStream("/zh/lexical.ctx");
seg = new SegTag(1, coreDictIn, bigramDictIn, personTaggerDctIn, personTaggerCtxIn,
transPersonTaggerDctIn, transPersonTaggerCtxIn, placeTaggerDctIn, placeTaggerCtxIn,
lexTaggerCtxIn);
}
}