[libpc] property tree / options

Howard Butler hobu.inc at gmail.com
Fri Mar 25 09:14:16 EDT 2011


On Mar 24, 2011, at 11:07 PM, Michael P. Gerlek wrote:

> At the sprint, we came up with a plan for using property trees to pass
> options to Stages -- or something like that.  I can't make heads or tails of
> my notes.  Can someone pls summarize the plan we made?

I believe the plan was something like:

* Give each stage a public Initialize(boost::property_tree::ptree& tree) method that each stage's constructor can choose to call or not in its ctors
* Give each stage a public ValidateOptions() method that throws libpc::validation_errors if something isn't right.
* Give each stage a public boost::property_tree::ptree GetDefaultOptions() that fills out a default tree that the user can then tweak values of and set on Initialize

I'm not sure this is the way to go even though I lean this way...

Howard


More information about the pdal mailing list