Boost  v1.57.0
doxygen for www.boost.org
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
boost::basic_settings_section< CharT > Class Template Reference

The class represents a reference to the settings container section. More...

#include <settings.hpp>

Inheritance diagram for boost::basic_settings_section< CharT >:
Collaboration diagram for boost::basic_settings_section< CharT >:

Public Types

typedef CharT char_type
 Character type. More...
 
typedef std::basic_string
< char_type
string_type
 String type. More...
 
typedef
property_tree::basic_ptree
< std::string, string_type
property_tree_type
 Property tree type. More...
 
typedef
property_tree_type::path_type 
path_type
 Property tree path type. More...
 
typedef ref< true > const_reference
 
typedef ref< false > reference
 
typedef iter< true > const_iterator
 
typedef iter< false > iterator
 
typedef std::reverse_iterator
< const_iterator
const_reverse_iterator
 
typedef std::reverse_iterator
< iterator
reverse_iterator
 

Public Member Functions

 basic_settings_section ()
 Default constructor. More...
 
 basic_settings_section (basic_settings_section const &that)
 Copy constructor. More...
 
bool operator! () const BOOST_NOEXCEPT
 Checks if the section refers to the container. More...
 
iterator begin ()
 Returns an iterator over the nested subsections and parameters. More...
 
iterator end ()
 Returns an iterator over the nested subsections and parameters. More...
 
const_iterator begin () const
 Returns an iterator over the nested subsections and parameters. More...
 
const_iterator end () const
 Returns an iterator over the nested subsections and parameters. More...
 
reverse_iterator rbegin ()
 Returns a reverse iterator over the nested subsections and parameters. More...
 
reverse_iterator rend ()
 Returns a reverse iterator over the nested subsections and parameters. More...
 
const_reverse_iterator rbegin () const
 Returns a reverse iterator over the nested subsections and parameters. More...
 
const_reverse_iterator rend () const
 Returns a reverse iterator over the nested subsections and parameters. More...
 
bool empty () const
 Checks if the container is empty (i.e. More...
 
reference operator[] (std::string const &section_name)
 Accessor to a single parameter. More...
 
const_reference operator[] (std::string const &section_name) const
 Accessor to a single parameter. More...
 
reference operator[] (const char *section_name)
 Accessor to a single parameter. More...
 
const_reference operator[] (const char *section_name) const
 Accessor to a single parameter. More...
 
property_tree_type const & property_tree () const
 Accessor for the embedded property tree. More...
 
property_tree_typeproperty_tree ()
 Accessor for the embedded property tree. More...
 
bool has_section (string_type const &section_name) const
 Checks if the specified section is present in the container. More...
 
bool has_parameter (string_type const &section_name, string_type const &param_name) const
 Checks if the specified parameter is present in the container. More...
 
void swap (basic_settings_section &that)
 Swaps two references to settings sections. More...
 

Protected Member Functions

 basic_settings_section (property_tree_type *tree)
 

Protected Attributes

property_tree_typem_ptree
 Parameters. More...
 

Friends

template<typename SectionT , bool IsConstV>
struct aux::basic_settings_section_iterator_base
 
template<bool IsConstV>
class ref
 
template<bool IsConstV>
class iter
 

Detailed Description

template<typename CharT>
class boost::basic_settings_section< CharT >

The class represents a reference to the settings container section.

The section refers to a sub-tree of the library settings container. It does not own the referred sub-tree but allows for convenient access to parameters within the subsection.

Member Typedef Documentation

template<typename CharT>
typedef CharT boost::basic_settings_section< CharT >::char_type

Character type.

template<typename CharT>
typedef iter< true > boost::basic_settings_section< CharT >::const_iterator
template<typename CharT>
typedef ref< true > boost::basic_settings_section< CharT >::const_reference
template<typename CharT>
typedef std::reverse_iterator< const_iterator > boost::basic_settings_section< CharT >::const_reverse_iterator
template<typename CharT>
typedef iter< false > boost::basic_settings_section< CharT >::iterator
template<typename CharT>
typedef property_tree_type::path_type boost::basic_settings_section< CharT >::path_type

Property tree path type.

template<typename CharT>
typedef property_tree::basic_ptree< std::string, string_type > boost::basic_settings_section< CharT >::property_tree_type

Property tree type.

template<typename CharT>
typedef ref< false > boost::basic_settings_section< CharT >::reference
template<typename CharT>
typedef std::reverse_iterator< iterator > boost::basic_settings_section< CharT >::reverse_iterator
template<typename CharT>
typedef std::basic_string< char_type > boost::basic_settings_section< CharT >::string_type

String type.

Constructor & Destructor Documentation

template<typename CharT>
boost::basic_settings_section< CharT >::basic_settings_section ( )
inline

Default constructor.

Creates an empty settings container.

template<typename CharT>
boost::basic_settings_section< CharT >::basic_settings_section ( basic_settings_section< CharT > const &  that)
inline

Copy constructor.

template<typename CharT>
boost::basic_settings_section< CharT >::basic_settings_section ( property_tree_type tree)
inlineexplicitprotected

Member Function Documentation

template<typename CharT>
iterator boost::basic_settings_section< CharT >::begin ( void  )
inline

Returns an iterator over the nested subsections and parameters.

References boost::property_tree::basic_ptree< Key, Data, KeyCompare >::begin().

Referenced by boost::basic_settings_section< CharT >::rbegin().

template<typename CharT>
const_iterator boost::basic_settings_section< CharT >::begin ( void  ) const
inline

Returns an iterator over the nested subsections and parameters.

References boost::property_tree::basic_ptree< Key, Data, KeyCompare >::begin().

template<typename CharT>
bool boost::basic_settings_section< CharT >::empty ( void  ) const
inline

Checks if the container is empty (i.e.

contains no sections and parameters).

References boost::property_tree::basic_ptree< Key, Data, KeyCompare >::empty().

template<typename CharT>
iterator boost::basic_settings_section< CharT >::end ( void  )
inline

Returns an iterator over the nested subsections and parameters.

References boost::property_tree::basic_ptree< Key, Data, KeyCompare >::end().

Referenced by boost::basic_settings_section< CharT >::rend().

template<typename CharT>
const_iterator boost::basic_settings_section< CharT >::end ( void  ) const
inline

Returns an iterator over the nested subsections and parameters.

References boost::property_tree::basic_ptree< Key, Data, KeyCompare >::end().

template<typename CharT>
bool boost::basic_settings_section< CharT >::has_parameter ( string_type const &  section_name,
string_type const &  param_name 
) const
inline

Checks if the specified parameter is present in the container.

Parameters
section_nameThe name of the section in which the parameter resides
param_nameThe name of the parameter

References boost::property_tree::basic_ptree< Key, Data, KeyCompare >::get_child_optional().

template<typename CharT>
bool boost::basic_settings_section< CharT >::has_section ( string_type const &  section_name) const
inline

Checks if the specified section is present in the container.

Parameters
section_nameThe name of the section

References boost::property_tree::basic_ptree< Key, Data, KeyCompare >::get_child_optional().

template<typename CharT>
bool boost::basic_settings_section< CharT >::operator! ( ) const
inline

Checks if the section refers to the container.

Checks if the section refers to the container.

References boost::basic_settings_section< CharT >::m_ptree.

template<typename CharT>
reference boost::basic_settings_section< CharT >::operator[] ( std::string const &  section_name)
inline

Accessor to a single parameter.

This operator should be used in conjunction with the subsequent subscript operator that designates the parameter name.

Parameters
section_nameThe name of the section in which the parameter resides
Returns
An unspecified reference type that can be used for parameter name specifying
template<typename CharT>
const_reference boost::basic_settings_section< CharT >::operator[] ( std::string const &  section_name) const
inline

Accessor to a single parameter.

This operator should be used in conjunction with the subsequent subscript operator that designates the parameter name.

Parameters
section_nameThe name of the section in which the parameter resides
Returns
An unspecified reference type that can be used for parameter name specifying
template<typename CharT>
reference boost::basic_settings_section< CharT >::operator[] ( const char *  section_name)
inline

Accessor to a single parameter.

This operator should be used in conjunction with the subsequent subscript operator that designates the parameter name.

Parameters
section_nameThe name of the section in which the parameter resides
Returns
An unspecified reference type that can be used for parameter name specifying
template<typename CharT>
const_reference boost::basic_settings_section< CharT >::operator[] ( const char *  section_name) const
inline

Accessor to a single parameter.

This operator should be used in conjunction with the subsequent subscript operator that designates the parameter name.

Parameters
section_nameThe name of the section in which the parameter resides
Returns
An unspecified reference type that can be used for parameter name specifying
template<typename CharT>
property_tree_type const& boost::basic_settings_section< CharT >::property_tree ( ) const
inline

Accessor for the embedded property tree.

References boost::basic_settings_section< CharT >::m_ptree.

template<typename CharT>
property_tree_type& boost::basic_settings_section< CharT >::property_tree ( )
inline

Accessor for the embedded property tree.

References boost::basic_settings_section< CharT >::m_ptree.

template<typename CharT>
reverse_iterator boost::basic_settings_section< CharT >::rbegin ( )
inline

Returns a reverse iterator over the nested subsections and parameters.

References boost::basic_settings_section< CharT >::begin().

template<typename CharT>
const_reverse_iterator boost::basic_settings_section< CharT >::rbegin ( ) const
inline

Returns a reverse iterator over the nested subsections and parameters.

References boost::basic_settings_section< CharT >::begin().

template<typename CharT>
reverse_iterator boost::basic_settings_section< CharT >::rend ( )
inline

Returns a reverse iterator over the nested subsections and parameters.

References boost::basic_settings_section< CharT >::end().

template<typename CharT>
const_reverse_iterator boost::basic_settings_section< CharT >::rend ( ) const
inline

Returns a reverse iterator over the nested subsections and parameters.

References boost::basic_settings_section< CharT >::end().

template<typename CharT>
void boost::basic_settings_section< CharT >::swap ( basic_settings_section< CharT > &  that)
inline

Friends And Related Function Documentation

template<typename CharT>
template<typename SectionT , bool IsConstV>
friend struct aux::basic_settings_section_iterator_base
friend
template<typename CharT>
template<bool IsConstV>
friend class iter
friend
template<typename CharT>
template<bool IsConstV>
friend class ref
friend

Member Data Documentation


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