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

Method prepared

filters/ExpressionStatsFilter.cpp:93–115  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

91
92
93void ExpressionStatsFilter::prepared(PointTableRef table)
94{
95 const PointLayoutPtr layout(table.layout());
96
97 m_dimId = layout->findDim(m_dimName);
98 if (m_dimId == Dimension::Id::Unknown)
99 throwError("Invalid dimension name in 'dimension' option: '" + m_dimName + "'.");
100
101 for (auto& expression: m_args->m_expressions)
102 {
103 if (!expression.valid())
104 {
105 std::stringstream oss;
106 oss << "The expression '" << expression
107 << "' is invalid";
108 throwError(oss.str());
109 }
110
111 auto status = expression.prepare(table.layout());
112 if (!status)
113 throwError("Invalid expression: " + status.what());
114 }
115}
116
117
118bool ExpressionStatsFilter::processOne(PointRef& point)

Callers

nothing calls this directly

Calls 5

strMethod · 0.80
findDimMethod · 0.45
validMethod · 0.45
prepareMethod · 0.45
whatMethod · 0.45

Tested by

no test coverage detected