MCPcopy Create free account
hub / github.com/Serial-Studio/Serial-Studio / AddRow

Method AddRow

lib/mdflib/mdfviewer/src/util/csvwriter.cpp:154–170  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

152}
153
154void CsvWriter::AddRow() {
155 if (column_count_ == 0 && row_count_ == 0) {
156 return; // No empty lines allowed
157 }
158 if (output_ != nullptr) {
159 if (column_count_ < max_columns_) {
160 for (auto ii = column_count_; ii < max_columns_; ++ii) {
161 if (ii > 0) {
162 *output_ << ",";
163 }
164 }
165 }
166 *output_ << std::endl;
167 }
168 ++row_count_;
169 column_count_ = 0;
170}
171
172void CsvWriter::CloseFile() {
173 if (file_.is_open()) {

Callers 1

CreateCsvFileFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected