//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET: //ORIGINAL LINE: public static void CheckLexRecords(java.util.Vector<gov.nih.nlm.nls.lexCheck.Lib.LexRecord> lexRecords, java.io.BufferedWriter out, java.io.BufferedWriter dupOut, boolean verbose, java.util.Hashtable<String, java.util.HashSet<String>> dupRecExpList, java.util.HashSet<String> notBaseFormSet) throws java.io.IOException public static void CheckLexRecords(List <LexRecord> lexRecords, System.IO.StreamWriter @out, System.IO.StreamWriter dupOut, bool verbose, Dictionary <string, HashSet <string> > dupRecExpList, HashSet <string> notBaseFormSet) { if (verbose == true) { Console.WriteLine("===== Check Lexicon Cross-Ref Contents ====="); } ErrMsgUtil.ResetErrMsg(); bool validFlag = true; bool dupEuiFlag = CrossCheckDupEuis.Check(lexRecords); bool dupRecFlag = CrossCheckDupLexRecords.Check(lexRecords, dupRecExpList, dupOut, verbose); validFlag = (dupEuiFlag) && (dupRecFlag); int recSize = lexRecords.Count; for (int i = 0; i < recSize; i++) { LexRecord lexRecord = (LexRecord)lexRecords[i]; bool nomFlag = CrossCheckNomEui.Check(lexRecord); bool abbFlag = CrossCheckAbbEui.Check(lexRecord, notBaseFormSet); bool acrFlag = CrossCheckAcrEui.Check(lexRecord, notBaseFormSet); validFlag = (validFlag) && (nomFlag) && (abbFlag) && (acrFlag); if (@out != null) { string text = lexRecord.GetText(); @out.Write(text); } } bool symFlag = CrossCheckNomSym.Check(lexRecords); validFlag = (symFlag) && (validFlag); if (!validFlag) { Console.WriteLine(ErrMsgUtil.GetErrMsg()); } Console.WriteLine("----- Total lexRecords checked: " + recSize); Console.WriteLine("----- cross-ref content error type stats -----"); Console.WriteLine(ErrMsgUtilLexicon.GetErrStats()); }
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET: //ORIGINAL LINE: public static void CheckLexRecords(java.util.Vector<gov.nih.nlm.nls.lexCheck.Lib.LexRecord> lexRecords, java.io.BufferedWriter out, boolean verbose, java.util.HashSet<String> irregExpEuiList) throws Exception public static void CheckLexRecords(List <LexRecord> lexRecords, System.IO.StreamWriter @out, bool verbose, HashSet <string> irregExpEuiList) { int errRecordNo = 0; int okRecordNo = 0; int recSize = lexRecords.Count; if (verbose == true) { Console.WriteLine("===== Check LexRecord Contents ====="); } if (lexRecords.Count > 0) { for (int i = 0; i < recSize; i++) { LexRecord lexRecord = (LexRecord)lexRecords[i]; if (verbose == true) { Console.WriteLine("--- Checking: " + lexRecord.GetEui() + " ---"); } if (!StaticCheckLexRecord(lexRecord, irregExpEuiList)) { Console.WriteLine(ErrMsgUtil.GetErrMsg()); errRecordNo++; } else { okRecordNo++; } if (@out != null) { string text = lexRecord.GetText(); @out.Write(text); } } } Console.WriteLine("----- Total lexRecords checked: " + recSize); Console.WriteLine("--- lexRecord has no error: " + okRecordNo); Console.WriteLine("--- lexRecord has error(s): " + errRecordNo); Console.WriteLine("----- content error type stats -----"); Console.WriteLine(ErrMsgUtilLexRecord.GetErrStats()); }