package OEI.SVQ.MPC.fhmm.E; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.util.HashMap; import java.util.Iterator; import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; //import java.util.concurrent.HashMap; import java.util.concurrent.CopyOnWriteArrayList; import AVQ.ASQ.OVQ.OSQ.VSQ.obj.FMHMMNode; import AVQ.ASQ.OVQ.OSQ.VSQ.obj.FMHMMPOS; import SVQ.stable.StablePOS; import SVQ.stable.StableMaps; import OCI.SVQ.MPC.fhmm.C.FHMMList; import PEU.P.nlp.*; //I will build a collection class for managing this maps. //at the next version. @SuppressWarnings("unchecked") //作者,著作权人: 罗瑶光,浏阳 public class FMHMMListOneTime_E implements FHMMList { private Map studyPos; private Map posCnToCn; private Map posEnToEn; private Map posEnToCn; private Map enToCn; private Map cnToEn; private Map fullEnToCn; private Map fullCnToEn; private Map fullCnToFn; private Map fullCnToKo; private Map fullCnToJp; private Map fullCnToSp; private Map fullCnToAb; private Map fullCnToGm; private Map fullCnToRs; private Map fullCnToPy; private Map fullCnToTt; private Map fullPositive; private Map fullNegative; private List listEn; private List listCn; private List listFn; private List listKo; private List listJp; private List listSp; private List listGm; private List listRs; private List listAb; private List listPy; private List listTt; public Map POSHashMap; public Map linkedHashMap; public Map getMap() { return this.linkedHashMap; } public Map[] getMaps() { int segment= this.linkedHashMap.size(); int perRatio= segment/ StablePOS.INT_SIX; Map[] maps= new HashMap[StablePOS.INT_SIX]; Iterator iterator= this.linkedHashMap.keySet().iterator(); maps[StablePOS.INT_ZERO]= new HashMap<>(); int index= StablePOS.INT_ZERO; int count= StablePOS.INT_ONE; while(iterator.hasNext()) { if(StablePOS.INT_ZERO== count++ % perRatio) { if(index< StablePOS.INT_FIVE) { index++; maps[index]= new HashMap<>(); } } Long key= iterator.next(); maps[index].put(key, this.linkedHashMap.get(key)); } return maps; } public void indexAll() throws IOException { studyPos= new ConcurrentHashMap<>(); posCnToCn= new ConcurrentHashMap<>(); linkedHashMap= new ConcurrentHashMap<>(); listCn= new CopyOnWriteArrayList<>(); listAb= new CopyOnWriteArrayList<>(); listKo= new CopyOnWriteArrayList<>(); listJp= new CopyOnWriteArrayList<>(); listRs= new CopyOnWriteArrayList<>(); listTt= new CopyOnWriteArrayList<>(); listEn= new CopyOnWriteArrayList<>(); listPy= new CopyOnWriteArrayList<>(); InputStream inputStream = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_CN); BufferedReader cReader = new BufferedReader(new InputStreamReader(inputStream, StablePOS.UTF8_STRING)); InputStream inputStreamKorea = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_KO); BufferedReader cReaderKorea = new BufferedReader(new InputStreamReader(inputStreamKorea, StablePOS.UTF8_STRING)); InputStream inputStreamJapan = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_JP); BufferedReader cReaderJapan = new BufferedReader(new InputStreamReader(inputStreamJapan, StablePOS.UTF8_STRING)); InputStream inputStreamTrandition = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_TT); BufferedReader cReaderTrandition = new BufferedReader(new InputStreamReader(inputStreamTrandition, StablePOS.UTF8_STRING)); InputStream inputStreamEnglish = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_EN_TO_EN); BufferedReader cReaderEnglish = new BufferedReader(new InputStreamReader(inputStreamEnglish, StablePOS.UTF8_STRING)); InputStream inputStreamPinYin = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_PY); BufferedReader cReaderPinYin = new BufferedReader(new InputStreamReader(inputStreamPinYin, StablePOS.UTF8_STRING)); InputStream inputStreamRs = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_RS); BufferedReader cReaderRs = new BufferedReader(new InputStreamReader(inputStreamRs, StablePOS.UTF8_STRING)); InputStream inputStreamAb = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_AB); BufferedReader cReaderAb = new BufferedReader(new InputStreamReader(inputStreamAb, StablePOS.UTF8_STRING)); String cInputString; String cInputStringKorea; String cInputStringJapan; String cInputStringTrandition; String cInputStringEnglish; String cInputStringPinYin; String cInputStringRs; String cInputStringAb; Here: while ((cInputString = cReader.readLine()) != null) { cInputStringKorea= cReaderKorea.readLine(); cInputStringJapan= cReaderJapan.readLine(); cInputStringTrandition= cReaderTrandition.readLine(); cInputStringEnglish= cReaderEnglish.readLine(); cInputStringPinYin= cReaderPinYin.readLine(); cInputStringRs= cReaderRs.readLine(); cInputStringAb= cReaderAb.readLine(); listCn.add(cInputString); if(null!= cInputStringKorea) { listKo.add(cInputStringKorea); // } if(null!= cInputStringJapan) { listJp.add(cInputStringJapan); // } if(null!= cInputStringTrandition) { listTt.add(cInputStringTrandition); // if(StablePOS.INT_ONE== cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].length()) { StableMaps.CiOne.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(StablePOS.INT_TWO== cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].length()) { StableMaps.CiTwo.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(StablePOS.INT_THREE== cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].length()) { StableMaps.CiThree.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(StablePOS.INT_FOUR== cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].length()) { StableMaps.CiFour.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(null!= cInputStringEnglish) { listEn.add(cInputStringEnglish); // } if(null!= cInputStringPinYin) { listPy.add(cInputStringPinYin); } if(null!= cInputStringRs) { listRs.add(cInputStringRs); } if(null!= cInputStringAb) { listAb.add(cInputStringAb); } if(!(!cInputString.replace(StablePOS.SPACE_STRING , StablePOS.EMPTY_STRING).equals(StablePOS.EMPTY_STRING) && cInputString.split(StablePOS.NLP_SYMBO_SLASH).length > StablePOS.INT_ONE )) { continue Here; } if(StablePOS.INT_ONE== cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].length()) { StableMaps.CiOne.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(StablePOS.INT_TWO== cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].length()) { StableMaps.CiTwo.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(StablePOS.INT_THREE== cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].length()) { StableMaps.CiThree.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(StablePOS.INT_FOUR== cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].length()) { StableMaps.CiFour.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.fuCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_FU)) { StableMaps.fuCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.fuCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.fuCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.fuCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.fuCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.dongCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_DONG)) { StableMaps.dongCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.dongCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.dongCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.dongCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.dongCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.liangCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_LIANG)) { StableMaps.liangCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.liangCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.liangCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.liangCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.liangCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.lianCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_LIAN)) { StableMaps.lianCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.lianCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.lianCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.lianCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.lianCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.baDongCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_BA_DONG)) { StableMaps.baDongCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.baDongCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.baDongCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.baDongCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.baDongCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.xianDingCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_XIAN_DING)) { StableMaps.xianDingCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.xianDingCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.xianDingCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.xianDingCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.xianDingCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.mingCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_MING)) { StableMaps.mingCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.mingCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.mingCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.mingCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.mingCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.daiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_DAI)) { StableMaps.daiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.daiCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.daiCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.daiCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.daiCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.jieCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE].contains(StablePOS.NLP_CI_JIE)) { StableMaps.jieCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.jieCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.jieCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.jieCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.jieCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.xingRongCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_XING_RONG)) { StableMaps.xingRongCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.xingRongCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.xingRongCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.xingRongCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.xingRongCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.zhuCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_ZHU)) { StableMaps.zhuCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.zhuCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.zhuCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.zhuCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.zhuCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.weiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_WEI)) { StableMaps.weiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.weiCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.weiCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.weiCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.weiCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.shengLueCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_SHENG_LUE)) { StableMaps.shengLueCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.shengLueCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.shengLueCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.shengLueCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.shengLueCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.qingTaiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_QING_TAI)) { StableMaps.qingTaiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.qingTaiCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.qingTaiCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.qingTaiCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.qingTaiCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.xingWeiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_XING_WEI)) { StableMaps.xingWeiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.xingWeiCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.xingWeiCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.xingWeiCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.xingWeiCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.shiTaiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_SHI_TAI)) { StableMaps.shiTaiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.shiTaiCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.shiTaiCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.shiTaiCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.shiTaiCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.dingMingCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_DING_MING)) { StableMaps.dingMingCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.dingMingCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.dingMingCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.dingMingCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.dingMingCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } studyPos.put(cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); posCnToCn.put(cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); linkedHashMap = loopLoadForest(cInputString); if(null!= cInputStringKorea) { posCnToCn.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); linkedHashMap = loopLoadForest(cInputStringKorea); } if(null!= cInputStringJapan) { if(!posCnToCn.containsKey(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO])) { posCnToCn.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH).length > StablePOS.INT_ONE?cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]:"未知"); linkedHashMap = loopLoadForest(cInputStringJapan); } } if(null!= cInputStringTrandition) { if(!posCnToCn.containsKey(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO])) { posCnToCn.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); linkedHashMap = loopLoadForest(cInputStringTrandition); } } if(null!= cInputStringEnglish) { posCnToCn.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase(), cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringRs) { posCnToCn.put(cInputStringRs .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase() , cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringAb) { posCnToCn.put(cInputStringAb .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase() , cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } cReader.close(); cReaderKorea.close(); cReaderJapan.close(); cReaderTrandition.close(); cReaderEnglish.close(); cReaderPinYin.close(); cReaderRs.close(); cReaderAb.close(); //trim StableMaps.baDongCi.remove(""); StableMaps.daiCi.remove(""); StableMaps.dingMingCi.remove(""); StableMaps.dongCi.remove(""); StableMaps.fuCi.remove(""); StableMaps.jieCi.remove(""); StableMaps.lianCi.remove(""); StableMaps.liangCi.remove(""); StableMaps.mingCi.remove(""); StableMaps.qingTaiCi.remove(""); StableMaps.shengLueCi.remove(""); StableMaps.shiTaiCi.remove(""); StableMaps.weiCi.remove(""); StableMaps.xianDingCi.remove(""); StableMaps.xingRongCi.remove(""); StableMaps.xingWeiCi.remove(""); StableMaps.zhuCi.remove(""); System.out.println(StableMaps.CiOne.size()); System.out.println(StableMaps.CiTwo.size()); System.out.println(StableMaps.CiThree.size()); System.out.println(StableMaps.CiFour.size()); } public void indexMixed() throws IOException { studyPos= new ConcurrentHashMap<>(); posCnToCn= new ConcurrentHashMap<>(); linkedHashMap= new ConcurrentHashMap<>(); listCn= new CopyOnWriteArrayList<>(); listAb= new CopyOnWriteArrayList<>(); listKo= new CopyOnWriteArrayList<>(); listJp= new CopyOnWriteArrayList<>(); listRs= new CopyOnWriteArrayList<>(); listTt= new CopyOnWriteArrayList<>(); listEn= new CopyOnWriteArrayList<>(); listPy= new CopyOnWriteArrayList<>(); InputStream inputStream = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_CN); BufferedReader cReader = new BufferedReader(new InputStreamReader(inputStream, StablePOS.UTF8_STRING)); InputStream inputStreamKorea = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_KO); BufferedReader cReaderKorea = new BufferedReader(new InputStreamReader(inputStreamKorea, StablePOS.UTF8_STRING)); InputStream inputStreamJapan = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_JP); BufferedReader cReaderJapan = new BufferedReader(new InputStreamReader(inputStreamJapan, StablePOS.UTF8_STRING)); InputStream inputStreamTrandition = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_TT); BufferedReader cReaderTrandition = new BufferedReader(new InputStreamReader(inputStreamTrandition, StablePOS.UTF8_STRING)); InputStream inputStreamEnglish = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_EN_TO_EN); BufferedReader cReaderEnglish = new BufferedReader(new InputStreamReader(inputStreamEnglish, StablePOS.UTF8_STRING)); InputStream inputStreamPinYin = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_PY); BufferedReader cReaderPinYin = new BufferedReader(new InputStreamReader(inputStreamPinYin, StablePOS.UTF8_STRING)); InputStream inputStreamRs = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_RS); BufferedReader cReaderRs = new BufferedReader(new InputStreamReader(inputStreamRs, StablePOS.UTF8_STRING)); InputStream inputStreamAb = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_AB); BufferedReader cReaderAb = new BufferedReader(new InputStreamReader(inputStreamAb, StablePOS.UTF8_STRING)); String cInputString; String cInputStringKorea; String cInputStringJapan; String cInputStringTrandition; String cInputStringEnglish; String cInputStringPinYin; String cInputStringRs; String cInputStringAb; Here: while ((cInputString = cReader.readLine()) != null) { cInputStringKorea= cReaderKorea.readLine(); cInputStringJapan= cReaderJapan.readLine(); cInputStringTrandition= cReaderTrandition.readLine(); cInputStringEnglish= cReaderEnglish.readLine(); cInputStringPinYin= cReaderPinYin.readLine(); cInputStringRs= cReaderRs.readLine(); cInputStringAb= cReaderAb.readLine(); listCn.add(cInputString); if(null!= cInputStringKorea) { listKo.add(cInputStringKorea); } if(null!= cInputStringJapan) { listJp.add(cInputStringJapan); } if(null!= cInputStringTrandition) { listTt.add(cInputStringTrandition); } if(null!= cInputStringEnglish) { listEn.add(cInputStringEnglish); } if(null!= cInputStringPinYin) { listPy.add(cInputStringPinYin); } if(null!= cInputStringRs) { listRs.add(cInputStringRs); } if(null!= cInputStringAb) { listAb.add(cInputStringAb); } if(!(!cInputString.replace(StablePOS.SPACE_STRING , StablePOS.EMPTY_STRING).equals(StablePOS.EMPTY_STRING) && cInputString.split(StablePOS.NLP_SYMBO_SLASH).length > StablePOS.INT_ONE )) { continue Here; } if(StablePOS.INT_ONE== cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].length()) { StableMaps.CiOne.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(StablePOS.INT_TWO== cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].length()) { StableMaps.CiTwo.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(StablePOS.INT_THREE== cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].length()) { StableMaps.CiThree.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(StablePOS.INT_FOUR== cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].length()) { StableMaps.CiFour.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.fuCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_FU)) { StableMaps.fuCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.fuCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.fuCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.fuCi.put(cInputStringTrandition. split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.fuCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.dongCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_DONG)) { StableMaps.dongCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.dongCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.dongCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.dongCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.dongCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.liangCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_LIANG)) { StableMaps.liangCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.liangCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.liangCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.liangCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.liangCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.lianCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_LIAN)) { StableMaps.lianCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.lianCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.lianCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.lianCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.lianCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.baDongCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_BA_DONG)) { StableMaps.baDongCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.baDongCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.baDongCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.baDongCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.baDongCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.xianDingCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_XIAN_DING)) { StableMaps.xianDingCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.xianDingCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.xianDingCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.xianDingCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.xianDingCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.mingCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_MING)) { StableMaps.mingCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.mingCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.mingCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.mingCi.put(cInputStringTrandition. split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.mingCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.daiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_DAI)) { StableMaps.daiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.daiCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.daiCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.daiCi.put(cInputStringTrandition. split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.daiCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.jieCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_JIE)) { StableMaps.jieCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.jieCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.jieCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.jieCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.jieCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.xingRongCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_XING_RONG)) { StableMaps.xingRongCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.xingRongCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.xingRongCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.xingRongCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.xingRongCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.zhuCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_ZHU)) { StableMaps.zhuCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.zhuCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.zhuCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.zhuCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.zhuCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.weiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ONE].contains(StablePOS.NLP_CI_WEI)) { StableMaps.weiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.weiCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.weiCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.weiCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.weiCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.shengLueCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_SHENG_LUE)) { StableMaps.shengLueCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.shengLueCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.shengLueCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.shengLueCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.shengLueCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.qingTaiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_QING_TAI)) { StableMaps.qingTaiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.qingTaiCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.qingTaiCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.qingTaiCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.qingTaiCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.xingWeiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_XING_WEI)) { StableMaps.xingWeiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.xingWeiCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.xingWeiCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.xingWeiCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.xingWeiCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.shiTaiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_SHI_TAI)) { StableMaps.shiTaiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.shiTaiCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.shiTaiCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.shiTaiCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.shiTaiCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } if(!StableMaps.dingMingCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_DING_MING)) { StableMaps.dingMingCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); if(null!= cInputStringKorea) { StableMaps.dingMingCi.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringJapan) { StableMaps.dingMingCi.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringTrandition) { StableMaps.dingMingCi.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringEnglish) { StableMaps.dingMingCi.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO],cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } studyPos.put(cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); posCnToCn.put(cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); linkedHashMap = loopLoadForest(cInputString); if(null!= cInputStringKorea) { posCnToCn.put(cInputStringKorea .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); linkedHashMap = loopLoadForest(cInputStringKorea); } if(null!= cInputStringJapan) { if(!posCnToCn.containsKey(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO])) { posCnToCn.put(cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] ,cInputStringJapan .split(StablePOS.NLP_SYMBO_SLASH).length> StablePOS.INT_ONE ? cInputStringJapan.split( StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]:"未知"); linkedHashMap = loopLoadForest(cInputStringJapan); } } if(null!= cInputStringTrandition) { if(!posCnToCn.containsKey(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO])) { posCnToCn.put(cInputStringTrandition .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); linkedHashMap = loopLoadForest(cInputStringTrandition); } } if(null!= cInputStringEnglish) { posCnToCn.put(cInputStringEnglish .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase() , cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringRs) { posCnToCn.put(cInputStringRs .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase() , cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(null!= cInputStringAb) { posCnToCn.put(cInputStringAb .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase() , cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } } cReader.close(); cReaderKorea.close(); cReaderJapan.close(); cReaderTrandition.close(); cReaderEnglish.close(); cReaderPinYin.close(); cReaderRs.close(); cReaderAb.close(); //trim StableMaps.baDongCi.remove(""); StableMaps.daiCi.remove(""); StableMaps.dingMingCi.remove(""); StableMaps.dongCi.remove(""); StableMaps.fuCi.remove(""); StableMaps.jieCi.remove(""); StableMaps.lianCi.remove(""); StableMaps.liangCi.remove(""); StableMaps.mingCi.remove(""); StableMaps.qingTaiCi.remove(""); StableMaps.shengLueCi.remove(""); StableMaps.shiTaiCi.remove(""); StableMaps.weiCi.remove(""); StableMaps.xianDingCi.remove(""); StableMaps.xingRongCi.remove(""); StableMaps.xingWeiCi.remove(""); StableMaps.zhuCi.remove(""); System.out.println(StableMaps.CiOne.size()); System.out.println(StableMaps.CiTwo.size()); System.out.println(StableMaps.CiThree.size()); System.out.println(StableMaps.CiFour.size()); } public void index() throws IOException { posCnToCn= new ConcurrentHashMap<>(); linkedHashMap= new ConcurrentHashMap<>(); listCn= new CopyOnWriteArrayList<>(); InputStream inputStream = getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_CN); BufferedReader cReader = new BufferedReader(new InputStreamReader(inputStream, StablePOS.UTF8_STRING)); String cInputString; Here: while ((cInputString = cReader.readLine())!= null) { listCn.add(cInputString); if(!(!cInputString.replace(StablePOS.SPACE_STRING , StablePOS.EMPTY_STRING).equals(StablePOS.EMPTY_STRING) && cInputString.split(StablePOS.NLP_SYMBO_SLASH).length > StablePOS.INT_ONE )) { continue Here; } if(!StableMaps.fuCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]. contains(StablePOS.NLP_CI_FU)) { StableMaps.fuCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.dongCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_DONG)) { StableMaps.dongCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.liangCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_LIANG)) { StableMaps.liangCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.lianCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_LIAN)) { StableMaps.lianCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.baDongCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_BA_DONG)) { StableMaps.baDongCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.xianDingCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_XIAN_DING)) { StableMaps.xianDingCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.mingCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_MING)) { StableMaps.mingCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.daiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_DAI)) { StableMaps.daiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.jieCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_JIE)) { StableMaps.jieCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.xingRongCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_XING_RONG)) { StableMaps.xingRongCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.zhuCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_ZHU)) { StableMaps.zhuCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.weiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_WEI)) { StableMaps.weiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.shengLueCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_SHENG_LUE)) { StableMaps.shengLueCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.qingTaiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_QING_TAI)) { StableMaps.qingTaiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.xingWeiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_XING_WEI)) { StableMaps.xingWeiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.shiTaiCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_SHI_TAI)) { StableMaps.shiTaiCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } if(!StableMaps.dingMingCi.containsKey(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]) && cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE] .contains(StablePOS.NLP_CI_DING_MING)) { StableMaps.dingMingCi.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } posCnToCn.put(cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); linkedHashMap = loopLoadForest(cInputString); } cReader.close(); } public void indexFullEnToCn() throws IOException { Iterator listcc= listCn.iterator(); Iterator listee= listEn.iterator(); fullEnToCn= new HashMap<>(); while(listcc.hasNext()&&listee.hasNext()) { fullEnToCn.put(listee.next() .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase() , listcc.next().split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO]); } } public void indexFullCnToEn() throws IOException { Iterator listcc= listCn.iterator(); Iterator listee= listEn.iterator(); fullCnToEn = new HashMap<>(); while(listcc.hasNext()&&listee.hasNext()) { fullCnToEn.put(listcc.next() .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , listee.next() .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase()); } } public void indexFullCnToFn() throws IOException { Iterator listcc= listCn.iterator(); Iterator listfn= listFn.iterator(); fullCnToFn = new HashMap<>(); while(listcc.hasNext()&&listfn.hasNext()) { fullCnToFn.put(listcc.next() .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , listfn.next().split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase()); } } public void indexFullCnToKo() throws IOException { Iterator listcc= listCn.iterator(); Iterator listko= listKo.iterator(); fullCnToKo = new HashMap<>(); while(listcc.hasNext()&&listko.hasNext()) { fullCnToKo.put(listcc.next() .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , listko.next().split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase()); } } public void indexFullCnToJp() throws IOException { Iterator listcc= listCn.iterator(); Iterator listjp= listJp.iterator(); fullCnToJp = new HashMap<>(); while(listcc.hasNext()&&listjp.hasNext()) { fullCnToJp.put(listcc.next() .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , listjp.next().split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase()); } } public void indexFullCnToGm() throws IOException { Iterator listcc= listCn.iterator(); Iterator listgm= listEn.iterator(); fullCnToGm = new HashMap<>(); while(listcc.hasNext()&&listgm.hasNext()) { fullCnToGm.put(listcc.next() .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , listgm.next().split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase()); } } public void indexFullCnToSp() throws IOException { Iterator listcc= listCn.iterator(); Iterator listsp= listSp.iterator(); fullCnToSp = new HashMap<>(); while(listcc.hasNext()&&listsp.hasNext()) { fullCnToSp.put(listcc.next() .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , listsp.next().split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase()); } } public void indexFullCnToRs() throws IOException { Iterator listcc= listCn.iterator(); Iterator listrs= listRs.iterator(); fullCnToRs = new HashMap<>(); while(listcc.hasNext()&&listrs.hasNext()) { fullCnToRs.put(listcc.next() .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , listrs.next().split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase()); } } public void indexFullCnToAb() throws IOException { Iterator listcc= listCn.iterator(); Iterator listab= listAb.iterator(); fullCnToAb = new HashMap<>(); while(listcc.hasNext()&&listab.hasNext()) { fullCnToAb.put(listcc.next() .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , listab.next().split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase()); } } public void indexFullCnToPy() throws IOException { Iterator listcc= listCn.iterator(); Iterator listpy= listPy.iterator(); fullCnToPy = new HashMap<>(); while(listcc.hasNext()&&listpy.hasNext()) { fullCnToPy.put(listcc.next() .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , listpy.next().split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase()); } } public void indexFullCnToTt() throws IOException { Iterator listcc= listCn.iterator(); Iterator listtt= listTt.iterator(); fullCnToTt = new HashMap<>(); while(listcc.hasNext()&&listtt.hasNext()) { fullCnToTt.put(listcc.next() .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO] , listtt.next().split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase()); } } public Map getFullEnToCn() { return this.fullEnToCn; } public Map getFullCnToEn() { return this.fullCnToEn; } public void indexPosEnToCn() throws IOException { posEnToCn= new HashMap<>(); InputStream in= getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_EN_TO_CN); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; Here: while (null!= (cInputString= cReader.readLine())) { if(!(!cInputString.replace(StablePOS.SPACE_STRING , StablePOS.EMPTY_STRING).equals(StablePOS.EMPTY_STRING) && cInputString.split(StablePOS.NLP_SYMBO_SLASH) .length > StablePOS.INT_ONE )) { continue Here; } posEnToCn.put(cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase() , cInputString.split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } cReader.close(); } public void indexFn() throws IOException { listFn= new CopyOnWriteArrayList<>(); InputStream in= getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_FN); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; while (null!= (cInputString= cReader.readLine())) { listFn.add(cInputString); } cReader.close(); } public void indexKo() throws IOException { listKo = new CopyOnWriteArrayList<>(); InputStream in = getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_KO); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; while (null!= (cInputString = cReader.readLine())) { listKo.add(cInputString); } cReader.close(); } public void indexJp() throws IOException { listJp = new CopyOnWriteArrayList<>(); InputStream in = getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_JP); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; while (null!= (cInputString = cReader.readLine())) { listJp.add(cInputString); } cReader.close(); } public void indexGm() throws IOException { listGm = new CopyOnWriteArrayList<>(); InputStream in = getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_GM); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; while (null!= (cInputString = cReader.readLine())) { listGm.add(cInputString); } cReader.close(); } public void indexSp() throws IOException { listSp = new CopyOnWriteArrayList<>(); InputStream in = getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_SP); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; while (null!= (cInputString = cReader.readLine())) { listSp.add(cInputString); } cReader.close(); } public void indexAb() throws IOException { listAb = new CopyOnWriteArrayList<>(); InputStream in = getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_AB); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; while (null!= (cInputString = cReader.readLine())) { listAb.add(cInputString); } cReader.close(); } public void indexRs() throws IOException { listRs = new CopyOnWriteArrayList<>(); InputStream in = getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_RS); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; while (null!= (cInputString = cReader.readLine())) { listRs.add(cInputString); } cReader.close(); } public void indexPy() throws IOException { listPy = new CopyOnWriteArrayList<>(); InputStream in = getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_PY); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; while (null!= (cInputString = cReader.readLine())) { listPy.add(cInputString); } cReader.close(); } public void indexTt() throws IOException { listTt = new CopyOnWriteArrayList<>(); InputStream in = getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_CN_TO_TT); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; while (null!= (cInputString = cReader.readLine())) { listTt.add(cInputString); } cReader.close(); } public void indexPosEnToEn() throws IOException { posEnToEn = new HashMap<>(); listEn = new CopyOnWriteArrayList<>(); InputStream in = getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_EN_TO_EN); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; Here: while (null!= (cInputString = cReader.readLine())) { listEn.add(cInputString); if(!(!cInputString.replace(StablePOS.SPACE_STRING , StablePOS.EMPTY_STRING).equals(StablePOS.EMPTY_STRING) && cInputString.split(StablePOS .NLP_SYMBO_SLASH).length > StablePOS.INT_ONE )) { continue Here; } posEnToEn.put(cInputString.split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase(), cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE].toLowerCase()); } cReader.close(); } public void indexEnToCn() throws IOException { enToCn = new HashMap<>(); InputStream in = getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_EN_TO_CN); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; Here: while (null!= (cInputString = cReader.readLine())) { if(!(!cInputString.replace(StablePOS.SPACE_STRING , StablePOS.EMPTY_STRING).equals(StablePOS.EMPTY_STRING) && cInputString.split(StablePOS.NLP_SYMBO_SLASH).length > StablePOS.INT_ONE )) { continue Here; } enToCn.put(cInputString.split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ZERO].toLowerCase(), cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE]); } cReader.close(); } public void indexCnToEn() throws IOException { cnToEn = new HashMap<>(); InputStream in = getClass() .getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_CN_TO_EN); BufferedReader cReader = new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; Here: while (null!= (cInputString = cReader.readLine())) { if(!(!cInputString.replace(StablePOS.SPACE_STRING , StablePOS.EMPTY_STRING).equals(StablePOS.EMPTY_STRING) && cInputString.split(StablePOS.NLP_SYMBO_SLASH).length > StablePOS.INT_ONE )) { continue Here; } cnToEn.put(cInputString.split(StablePOS .NLP_SYMBO_SLASH)[StablePOS.INT_ZERO], cInputString .split(StablePOS.NLP_SYMBO_SLASH)[StablePOS.INT_ONE].toLowerCase()); } cReader.close(); } public Map loopLoadForest(String cInputString) { Here: for (int i = StablePOS.INT_ZERO; i < cInputString.length(); i++) { if (linkedHashMap.containsKey(Long.valueOf(cInputString.charAt(i)))) { FMHMMNode fHHMMNode = linkedHashMap.get(Long.valueOf(cInputString.charAt(i))); linkedHashMap = doNeroPostCognitive(fHHMMNode, cInputString, i); continue Here; } FMHMMNode fHHMMNode = new FMHMMNode(); fHHMMNode.I_Vb(StablePOS.EMPTY_STRING + cInputString.charAt(i)); if (i + StablePOS.INT_ONE < cInputString.length()) { Map next = new HashMap<>(); next.put(StablePOS.EMPTY_STRING + cInputString.charAt(i + StablePOS.INT_ONE), StablePOS.INT_ONE); fHHMMNode.I_Next(next); } linkedHashMap.put(Long.valueOf(cInputString.charAt(i)), fHHMMNode); } return linkedHashMap; } public Map doNeroPostCognitive(FMHMMNode fFHMMNode , String cInputString, int i) { if (null!= fFHMMNode.getNext()) { if (i + StablePOS.INT_ONE < cInputString.length()) { linkedHashMap = doCheckAndRunNeroPostFix(fFHMMNode, cInputString, i); } return linkedHashMap; } HashMap HashMap = new HashMap<>(); if (i + StablePOS.INT_ONE < cInputString.length()) { HashMap.put(StablePOS.EMPTY_STRING + cInputString.charAt(i + StablePOS.INT_ONE) ,StablePOS.INT_ONE); } fFHMMNode.I_Next(HashMap); linkedHashMap.put(Long.valueOf(cInputString.charAt(i)), fFHMMNode); return linkedHashMap; } public Map doCheckAndRunNeroPostFix(FMHMMNode fFHMMNode , String cInputString, int i) { if (!fFHMMNode.getNext().containsKey(StablePOS.EMPTY_STRING + cInputString.charAt(i + StablePOS.INT_ONE))) { Map map = fFHMMNode.getNext(); map.put(StablePOS.EMPTY_STRING + cInputString.charAt(i + StablePOS.INT_ONE), StablePOS.INT_ONE); fFHMMNode.I_Next(map); linkedHashMap.put(Long.valueOf(cInputString.charAt(i)), fFHMMNode); } return linkedHashMap; } public Map getPosCnToCn() { return this.posCnToCn; } public Map getEnToCn() { return enToCn; } public Map getCnToEn() { return cnToEn; } public Map getPosEnToCn() { return this.posEnToCn; } public Map getPosEnToEn() { return this.posEnToEn; } // if((string.charAt(i)> StableData.INT_SIXTY_FOUR //&& string.charAt(i)<= StableData.INT_NINTY) // ||(string.charAt(i)>= StableData.INT_NINTY_SEVEN //&& string.charAt(i)<= StableData.INT_ONE_TWO_TWO) // ||symbol.contains(StableData.EMPTY_STRING+ string.charAt(i)) { //sb.append(string.charAt(i)); //}else { //list.add(sb.toString().toLowerCase()); //sb.delete(StableData.INT_ZERO, sb.length()); //list.add(String.valueOf(string.charAt(i))); //} public List englishStringToWordsList(String string) { List list= new LinkedList<>(); string= string.replaceAll(StablePOS.NLP_SPASE_REP , StablePOS.SPACE_STRING); StringBuilder sb= new StringBuilder(); for(int i= 0; i< string.length(); i++) { if(StopSymbol_UTF8.symbol.contains(StablePOS.EMPTY_STRING + string.charAt(i))) { list.add(sb.toString().toLowerCase()); sb.delete(StablePOS.INT_ZERO, sb.length()); list.add(String.valueOf(string.charAt(i))); }else { sb.append(string.charAt(i)); } } if(StablePOS.INT_ZERO< sb.length()) { list.add(sb.toString().toLowerCase()); } return list; } public Map getFullCnToJp() { return this.fullCnToJp; } public Map getFullCnToRs() { return this.fullCnToRs; } public Map getFullCnToAb() { return this.fullCnToAb; } public Map getFullCnToFn() { return this.fullCnToFn; } public Map getFullCnToGm() { return this.fullCnToGm; } public Map getFullCnToKo() { return this.fullCnToKo; } public Map getFullCnToSp() { return this.fullCnToSp; } public Map getFullCnToPy() { this.fullCnToPy.put("鼋", "yuan");//这些我稍后也会移动到stable文件中去,免得乱码。 this.fullCnToPy.put("鹑", "chun"); this.fullCnToPy.put("鸲鹆", "qu yu"); this.fullCnToPy.put("鲚鱼", "ji yu"); this.fullCnToPy.put("鲎", "hou"); this.fullCnToPy.put("醍醐", "ti hu"); this.fullCnToPy.put("豹", "bao"); this.fullCnToPy.put("蟅", "zhe"); this.fullCnToPy.put("蛴螬", "qi cao"); this.fullCnToPy.put("蘹", "huai"); this.fullCnToPy.put("堇", "jin"); this.fullCnToPy.put("檗", "bo"); this.fullCnToPy.put("濮", "pu"); this.fullCnToPy.put("稆", "lv"); this.fullCnToPy.put("穬", "kuang"); this.fullCnToPy.put("箘", "jun"); this.fullCnToPy.put("芰", "ji"); this.fullCnToPy.put("茨菰", "ci gu"); this.fullCnToPy.put("荏", "ren"); this.fullCnToPy.put("荛", "rao"); this.fullCnToPy.put("菉", "lu"); this.fullCnToPy.put("菘", "song"); this.fullCnToPy.put("蕺", "ji"); this.fullCnToPy.put("蘩蒌", "fan cai"); return this.fullCnToPy; } public Map getFullCnToTt() { return this.fullCnToTt; } public void indexFullNegative() throws IOException { fullNegative= new HashMap<>(); InputStream in= getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_NEGATIVE); BufferedReader cReader= new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; while (null!= (cInputString= cReader.readLine())) { if(!fullNegative.containsKey(cInputString)) { fullNegative.put(cInputString, StablePOS.EMPTY_STRING); } } cReader.close(); } public void indexFullPositive() throws IOException { fullPositive= new HashMap<>(); InputStream in= getClass().getResourceAsStream(StablePOS.WORDS_SOURSE_LINK_POS_POSITIVE); BufferedReader cReader= new BufferedReader(new InputStreamReader(in, StablePOS.UTF8_STRING)); String cInputString; while (null!= (cInputString= cReader.readLine())) { if(!fullPositive.containsKey(cInputString)) { fullPositive.put(cInputString, StablePOS.EMPTY_STRING); } } cReader.close(); } public Map getFullNegative() { return this.fullNegative; } public Map getFullPositive() { return this.fullPositive; } @Override public Map> getWordsForests() { Map> output= new HashMap<>(); Iterator WordTree= posCnToCn.keySet().iterator(); while(WordTree.hasNext()){ String treeName= WordTree.next(); if(0 treeLeafs; if(output.containsKey(Long.valueOf(treeName.charAt(StablePOS.INT_ZERO)))){ treeLeafs= output.get(Long.valueOf(treeName.charAt(StablePOS.INT_ZERO))); treeLeafs.put(treeName, posCnToCn.get(treeName)); output.put(Long.valueOf(treeName.charAt(StablePOS.INT_ZERO)), treeLeafs); }else { treeLeafs= new HashMap<>(); } treeLeafs.put(treeName, posCnToCn.get(treeName)); output.put(Long.valueOf(treeName.charAt(StablePOS.INT_ZERO)), treeLeafs); } } return output; } public void studyNewPos(String string, String posStudy) { posCnToCn.put(string, posStudy); } @Override public Map getStudyPos() { return this.studyPos; } }