MCPcopy Create free account
hub / github.com/OpenMS/OpenMS / getRow

Method getRow

src/openms/source/FORMAT/CsvFile.cpp:62–82  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

60 }
61
62 bool CsvFile::getRow(Size row, StringList& list)
63 {
64 // it is assumed that the value to be cast won't be so large to overflow an ulong int
65 if (static_cast<int>(row) > static_cast<int>(TextFile::buffer_.size()) - 1)
66 {
67 throw Exception::InvalidIterator(__FILE__, __LINE__, OPENMS_PRETTY_FUNCTION);
68 }
69 bool splitted = buffer_[row].split(itemseperator_, list);
70 if (!splitted)
71 {
72 return splitted;
73 }
74 for (Size i = 0; i < list.size(); i++)
75 {
76 if (itemenclosed_)
77 {
78 list[i] = list[i].substr(1, list[i].size() - 2);
79 }
80 }
81 return true;
82 }
83
84 std::vector<String>::size_type CsvFile::rowCount() const
85 {

Callers 15

main_Method · 0.80
main_Method · 0.80
main_Method · 0.80
main_Method · 0.80
main_Method · 0.80
main_Method · 0.80
readPoutAsMap_Method · 0.80
parseLuciphorOutput_Method · 0.80
loadSamples_Method · 0.80
loadMethod · 0.80

Calls 3

substrMethod · 0.80
sizeMethod · 0.45
splitMethod · 0.45

Tested by 2

main_Method · 0.64
START_SECTIONFunction · 0.64