public DalvikOpcodeHelpLookup() { try { using (var csv = new CSVFile(GetType().Assembly.GetManifestResourceStream(DalvikOpcodesCsvRessource), QuoteChar.Quotes)) { var opAndFormat = ""; var mnemonic = ""; var arguments = ""; var description = ""; while (csv.NextRow()) { var curOpAndFormat = csv.String(0); var curMnemonic = csv.String(1); var curArguments = csv.String(2); var curDescription = csv.String(3); if (string.IsNullOrEmpty(curOpAndFormat) || string.IsNullOrEmpty(curMnemonic)) { // this is an addition to the previous line. if (!string.IsNullOrEmpty(curOpAndFormat)) { opAndFormat += "\n" + curOpAndFormat; } if (!string.IsNullOrEmpty(curMnemonic)) { mnemonic += "\n" + curMnemonic; } if (!string.IsNullOrEmpty(curArguments)) { arguments += "\n" + curArguments; } if (!string.IsNullOrEmpty(curDescription)) { description += curDescription; } } else { if (!string.IsNullOrEmpty(mnemonic)) { AddEntry(opAndFormat, mnemonic, arguments, description); } opAndFormat = curDescription; mnemonic = curMnemonic; arguments = curArguments; description = curDescription; } } if (!string.IsNullOrEmpty(mnemonic)) { AddEntry(opAndFormat, mnemonic, arguments, description); } } } catch (Exception ex) { DLog.Warning(DContext.CompilerCodeGenerator, "unable to parse opcode help: ", ex.Message); } }