dune-typetree  2.7.1
List of all members
Dune::TypeTree::DynamicChildAccessors< ProxiedNode > Class Template Reference

Mixin class providing methods for child access with run-time parameter. More...

#include <dune/typetree/proxynode.hh>

Inheritance diagram for Dune::TypeTree::DynamicChildAccessors< ProxiedNode >:
Inheritance graph

Detailed Description

template<typename ProxiedNode>
class Dune::TypeTree::DynamicChildAccessors< ProxiedNode >

Mixin class providing methods for child access with run-time parameter.

This class also provides the compile-time parameter based methods, as multiple inheritance from both DynamicChildAccessors and StaticChildAccessors creates ambigous method lookups.

Member Function Documentation

◆ child() [1/4]

template<typename ProxiedNode >
template<std::size_t k>
std::enable_if<lazy_enabled<k>::value,typename Child<k>::Type&>::type Dune::TypeTree::StaticChildAccessors< ProxiedNode >::child ( Dune::index_constant< k >  = {})
inlineinherited

Returns the i-th child.

Returns
a reference to the i-th child.

◆ child() [2/4]

template<typename ProxiedNode >
template<std::size_t k>
const Child<k>::Type& Dune::TypeTree::StaticChildAccessors< ProxiedNode >::child ( Dune::index_constant< k >  = {}) const
inlineinherited

Returns the i-th child (const version).

Returns
a const reference to the i-th child.

◆ child() [3/4]

template<typename ProxiedNode >
template<bool enabled = !proxiedNodeIsConst>
std::enable_if<enabled,typename ProxiedNode::ChildType&>::type Dune::TypeTree::DynamicChildAccessors< ProxiedNode >::child ( std::size_t  i)
inline

Returns the i-th child.

Returns
a reference to the i-th child.

◆ child() [4/4]

template<typename ProxiedNode >
const ProxiedNode::ChildType& Dune::TypeTree::DynamicChildAccessors< ProxiedNode >::child ( std::size_t  i) const
inline

Returns the i-th child (const version).

Returns
a const reference to the i-th child.

◆ childStorage() [1/4]

template<typename ProxiedNode >
template<std::size_t k>
std::enable_if<lazy_enabled<k>::value,typename Child<k>::Storage>::type Dune::TypeTree::StaticChildAccessors< ProxiedNode >::childStorage ( )
inlineinherited

Returns the storage of the i-th child.

Returns
a copy of the object storing the i-th child.

◆ childStorage() [2/4]

template<typename ProxiedNode >
template<std::size_t k>
Child<k>::ConstStorage Dune::TypeTree::StaticChildAccessors< ProxiedNode >::childStorage ( ) const
inlineinherited

Returns the storage of the i-th child (const version).

This method is only important if the child is stored as some kind of pointer, as this allows the pointee type to become const.

Returns
a copy of the object storing the i-th child.

◆ childStorage() [3/4]

template<typename ProxiedNode >
template<bool enabled = !proxiedNodeIsConst>
std::enable_if<enabled,typename ProxiedNode::ChildStorageType>::type Dune::TypeTree::DynamicChildAccessors< ProxiedNode >::childStorage ( std::size_t  i)
inline

Returns the storage of the i-th child.

Returns
a copy of the object storing the i-th child.

◆ childStorage() [4/4]

template<typename ProxiedNode >
ProxiedNode::ChildConstStorageType Dune::TypeTree::DynamicChildAccessors< ProxiedNode >::childStorage ( std::size_t  i) const
inline

Returns the storage of the i-th child (const version).

This method is only important if the child is stored as some kind of pointer, as this allows the pointee type to become const.

Returns
a copy of the object storing the i-th child.

◆ nodeStorage()

template<typename ProxiedNode >
const ProxiedNode::NodeStorage& Dune::TypeTree::StaticChildAccessors< ProxiedNode >::nodeStorage ( ) const
inlineinherited

◆ setChild() [1/4]

template<typename ProxiedNode >
template<bool enabled = !proxiedNodeIsConst>
void Dune::TypeTree::DynamicChildAccessors< ProxiedNode >::setChild ( std::size_t  i,
typename ProxiedNode::ChildStorageType  st,
typename std::enable_if< enabled, void * >::type  = 0 
)
inline

Sets the stored value representing the i-th child to the passed-in value.

◆ setChild() [2/4]

template<typename ProxiedNode >
template<bool enabled = !proxiedNodeIsConst>
void Dune::TypeTree::DynamicChildAccessors< ProxiedNode >::setChild ( std::size_t  i,
typename ProxiedNode::ChildType &  t,
typename std::enable_if< enabled, void * >::type  = 0 
)
inline

Sets the i-th child to the passed-in value.

◆ setChild() [3/4]

template<typename ProxiedNode >
template<std::size_t k>
void Dune::TypeTree::StaticChildAccessors< ProxiedNode >::setChild ( typename Child< k >::storage_type  child,
typename std::enable_if< lazy_enabled< k >::value, void * >::type  = 0 
)
inlineinherited

Sets the storage of the i-th child to the passed-in value.

◆ setChild() [4/4]

template<typename ProxiedNode >
template<std::size_t k>
void Dune::TypeTree::StaticChildAccessors< ProxiedNode >::setChild ( typename Child< k >::type &  child,
typename std::enable_if< lazy_enabled< k >::value, void * >::type  = 0 
)
inlineinherited

Sets the i-th child to the passed-in value.


The documentation for this class was generated from the following file: