48 #include <serialization/adapters/std/vector> 50 #ifndef _MIRA_PROPERTYTREE_H_ 51 #define _MIRA_PROPERTYTREE_H_ 100 template<
typename Reflector>
104 r.member(
"Children", children,
"");
107 std::list<Node> children;
113 node.children.clear();
116 node.children.push_back(*p);
117 createChildren(node.children.back(),p);
122 template <
typename PropertyNodeType>
123 void generateChildren(PropertyNodeType* pnode,
const Node& node)
const 126 foreach(
const Node& c, node.children)
128 PropertyNodeType* cn =
new PropertyNodeType(c);
130 generateChildren<PropertyNodeType>(cn, c);
149 createChildren(mRoot,root);
152 template<
typename Reflector>
155 r.member(
"Root", mRoot,
"");
175 template <
typename PropertyNodeType>
180 root =
new PropertyNodeType(mRoot);
182 generateChildren<PropertyNodeType>(root, mRoot);
Abstract base class for all derived property node classes.
Definition: PropertyNode.h:202
Definition: PropertyNode.h:72
Declaration and implementation of the property node hierarchy.
specialize cv::DataType for our ImgPixel and inherit from cv::DataType<Vec>
Definition: IOService.h:67
#define MIRA_REFLECT_BASE(reflector, BaseClass)
Macro that can be used to reflect the base class easily.
Definition: ReflectorInterface.h:912
virtual NodeList & children()
Returns a vector with all child property nodes.
Definition: PropertyNode.h:230
void reflect(Reflector &r)
Definition: PropertyTree.h:153
const PropertyNodeInfo & getRootNodeInfo() const
Returns the info for the root node, and therefore allows the user to create a root property node from...
Definition: PropertyTree.h:164
PropertyNodeType * generatePropertyNodes(PropertyNodeType *root=NULL) const
Reconstructs the property nodes from the given tree structure.
Definition: PropertyTree.h:176
PropertyTree(PropertyNode *root)
Constructs a property tree representation from a given property node and all of its child nodes...
Definition: PropertyTree.h:145
PropertyTree()
Creates an empty tree.
Definition: PropertyTree.h:137
Helper class that is able to hold a complete property tree structure.
Definition: PropertyTree.h:86