MCPcopy Create free account
hub / github.com/PDAL/PDAL / dump3

Method dump3

pdal/util/ProgramArgs.hpp:1429–1450  ·  view source on GitHub ↗

Write a JSON array of arguments to an output stream. \param out Stream to which output should be written. */

Source from the content-addressed store, hash-verified

1427
1428 */
1429 void dump3(std::ostream& out) const
1430 {
1431 out << "[";
1432 bool bFirst(true);
1433 for (auto ai = m_args.begin(); ai != m_args.end(); ++ai)
1434 {
1435 Arg *a = ai->get();
1436
1437 if (!bFirst)
1438 out << ",";
1439
1440 out << "{\"name\":\"" << a->longname() << "\"";
1441
1442 if (a->defaultProvided())
1443 out << ",\"default\":\"" << Utils::escapeJSON(a->defaultVal()) << "\"";
1444
1445 out << ",\"description\":\"" << Utils::escapeJSON(a->description()) << "\"}";
1446
1447 bFirst = false;
1448 }
1449 out << "]";
1450 }
1451
1452private:
1453 /*

Callers 1

outputOptionsMethod · 0.80

Calls 7

longnameMethod · 0.80
beginMethod · 0.45
endMethod · 0.45
getMethod · 0.45
defaultProvidedMethod · 0.45
defaultValMethod · 0.45
descriptionMethod · 0.45

Tested by

no test coverage detected