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

Method handleOptions

pdal/Stage.cpp:120–147  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

118
119
120void Stage::handleOptions()
121{
122 addAllArgs(*m_args);
123
124 StringList files = m_options.getValues("option_file");
125 for (std::string& file : files)
126 m_options.addConditional(Options::fromFile(file));
127 m_options.remove(Option("option_file", 0));
128
129 // Special stuff for GRiD so that no error is thrown when a file
130 // isn't found.
131 files = m_options.getValues("grid_option_file");
132 for (std::string& file : files)
133 m_options.addConditional(Options::fromFile(file, false));
134 m_options.remove(Option("grid_option_file", 0));
135
136 StringList cmdline = m_options.toCommandLine();
137 try
138 {
139 m_args->parse(cmdline);
140 }
141 catch (arg_error error)
142 {
143 throw pdal_error(getName() + ": " + error.what());
144 }
145 assignParsedOptions();
146 setupLog();
147}
148
149
150void Stage::assignParsedOptions()

Callers 1

prepareMethod · 0.80

Calls 8

addConditionalMethod · 0.80
removeMethod · 0.80
toCommandLineMethod · 0.80
OptionFunction · 0.70
assignParsedOptionsFunction · 0.70
getNameFunction · 0.50
parseMethod · 0.45
whatMethod · 0.45

Tested by

no test coverage detected