4 #ifndef DUNE_TYPETREE_CHILDEXTRACTION_HH
5 #define DUNE_TYPETREE_CHILDEXTRACTION_HH
7 #include <dune/common/documentation.hh>
8 #include <dune/common/static_assert.hh>
9 #include <dune/common/typetraits.hh>
10 #include <dune/common/shared_ptr.hh>
25 template<
typename Node,
typename TreePath>
52 #if HAVE_VARIADIC_TEMPLATES
55 template<
typename Node>
63 #else // HAVE_VARIADIC_TEMPLATES
67 template<
typename Node>
68 struct extract_child_type<Node,
70 noChildIndex,noChildIndex,
71 noChildIndex,noChildIndex,
72 noChildIndex,noChildIndex,
73 noChildIndex,noChildIndex,
74 noChildIndex,noChildIndex
83 #endif // HAVE_VARIADIC_TEMPLATES
115 template<
typename Node,
typename TreePath>
143 template<
typename Node,
typename TreePath>
153 template<
typename Node,
typename TreePath>
156 typename extract_child_type<Node,TreePath>::type&
164 template<
typename Node,
typename TreePath>
174 template<
typename Node,
typename TreePath>
188 template<
typename Node,
typename TreePath>
191 const typename extract_child_type<Node,TreePath>::type&
196 typename TypeTree::TreePathPopFront<TreePath>::type());
199 template<
typename Node,
typename TreePath>
209 template<
typename Node,
typename TreePath>
251 template<
typename Node,
typename TreePath>
280 template<
typename Node,
typename TreePath>
290 template<
typename Node,
typename TreePath>
293 typename extract_child_type<Node,TreePath>::storage_type
301 template<
typename Node,
typename TreePath>
311 template<
typename Node,
typename TreePath>
318 "extract_child_storage only works for real children, not the node itself.");
325 template<
typename Node,
typename TreePath>
328 typename extract_child_type<Node,TreePath>::const_storage_type
333 typename TypeTree::TreePathPopFront<TreePath>::type());
336 template<
typename Node,
typename TreePath>
346 template<
typename Node,
typename TreePath>
353 "extract_child_storage only works for real children, not the node itself.");
365 #endif // DUNE_TYPETREE_CHILDEXTRACTION_HH
Definition: treepath.hh:32
ImplementationDefined & extract_child(Node &node, Treepath tp)
Extract the child of a node located at tp (non-const version).
Definition: childextraction.hh:116
extract_child_type< typename Node::template Child< TypeTree::TreePathFront< TreePath >::value >::Type, typename TypeTree::TreePathPopFront< TreePath >::type >::storage_type storage_type
The storage type of the child.
Definition: childextraction.hh:39
extract_child_type< typename Node::template Child< TypeTree::TreePathFront< TreePath >::value >::Type, typename TypeTree::TreePathPopFront< TreePath >::type >::type type
The type of the child.
Definition: childextraction.hh:33
extract_child_type< typename Node::template Child< TypeTree::TreePathFront< TreePath >::value >::Type, typename TypeTree::TreePathPopFront< TreePath >::type >::const_storage_type const_storage_type
The const storage type of the child.
Definition: childextraction.hh:45
Definition: treepath.hh:39
Extract the type of the child of Node at position TreePath.
Definition: childextraction.hh:26
static const std::size_t value
Definition: compositenode.hh:38
Type
Definition: treepath.hh:26
Definition: treepath.hh:84
Definition: treepath.hh:109
ImplementationDefined extract_child_storage(Node &node, Treepath tp)
Definition: childextraction.hh:252