All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Protected Member Functions | Protected Attributes
castor::Configuration Class Reference

#include <Configuration.h>

List of all members.

Public Member Functions

 Configuration ()
 Configuration (std::string filename)
 Configuration (std::string filename, const std::string content)
template<typename T >
get (const char *path,...)
template<typename T >
boost::shared_ptr< std::vector
< T > > 
getAll (const char *path,...)
boost::shared_ptr< std::vector
< std::string > > 
getNames (const char *path,...)
boost::shared_ptr< std::vector
< std::string > > 
getSections (const char *path,...)
void load (std::string filename)
void load (std::string filename, boost::shared_ptr< std::istream > content, bool create, bool replace)
std::string serialize ()
template<typename T >
void set (T value, const char *path,...)
void store ()
void store (std::string filename)
template<typename T >
tryGet (T d, const char *path,...)
template<typename T >
boost::shared_ptr< std::vector
< T > > 
tryGetAll (T d, const char *path,...)
boost::shared_ptr< std::vector
< std::string > > 
tryGetNames (std::string d, const char *path,...)
boost::shared_ptr< std::vector
< std::string > > 
tryGetSections (std::string d, const char *path,...)

Protected Member Functions

void collect (ConfigNode *node, std::vector< std::string > *params, size_t offset, std::vector< ConfigNode * > *result)
void collectSections (ConfigNode *node, std::vector< std::string > *params, size_t offset, std::vector< ConfigNode * > *result)
template<typename Target >
Target convert (std::string value)
std::string pathNotFound (std::vector< std::string > *params)
void serialize_internal (std::ostringstream *ss, ConfigNode *node)

Protected Attributes

ConfigNodePtr configRoot
std::string filename

Detailed Description

Definition at line 168 of file Configuration.h.


Constructor & Destructor Documentation

Definition at line 21 of file Configuration.cpp.

castor::Configuration::Configuration ( std::string  filename)

Definition at line 26 of file Configuration.cpp.

castor::Configuration::Configuration ( std::string  filename,
const std::string  content 
)

Definition at line 32 of file Configuration.cpp.


Member Function Documentation

void castor::Configuration::collect ( ConfigNode node,
std::vector< std::string > *  params,
size_t  offset,
std::vector< ConfigNode * > *  result 
) [protected]

Definition at line 256 of file Configuration.cpp.

void castor::Configuration::collectSections ( ConfigNode node,
std::vector< std::string > *  params,
size_t  offset,
std::vector< ConfigNode * > *  result 
) [protected]

Definition at line 281 of file Configuration.cpp.

template<typename Target >
Target castor::Configuration::convert ( std::string  value) [inline, protected]

Definition at line 179 of file Configuration.h.

template<typename T >
T castor::Configuration::get ( const char *  path,
  ... 
) [inline]

Definition at line 216 of file Configuration.h.

template<typename T >
boost::shared_ptr<std::vector<T> > castor::Configuration::getAll ( const char *  path,
  ... 
) [inline]

Definition at line 232 of file Configuration.h.

boost::shared_ptr< std::vector< std::string > > castor::Configuration::getNames ( const char *  path,
  ... 
)

Definition at line 381 of file Configuration.cpp.

boost::shared_ptr< std::vector< std::string > > castor::Configuration::getSections ( const char *  path,
  ... 
)

Definition at line 347 of file Configuration.cpp.

void castor::Configuration::load ( std::string  filename) [inline]

Definition at line 206 of file Configuration.h.

void castor::Configuration::load ( std::string  filename,
boost::shared_ptr< std::istream >  content,
bool  create,
bool  replace 
)

Definition at line 38 of file Configuration.cpp.

std::string castor::Configuration::pathNotFound ( std::vector< std::string > *  params) [protected]

Definition at line 325 of file Configuration.cpp.

Definition at line 248 of file Configuration.cpp.

void castor::Configuration::serialize_internal ( std::ostringstream *  ss,
ConfigNode node 
) [protected]

Definition at line 204 of file Configuration.cpp.

template<typename T >
void castor::Configuration::set ( value,
const char *  path,
  ... 
) [inline]

Definition at line 296 of file Configuration.h.

Definition at line 231 of file Configuration.cpp.

void castor::Configuration::store ( std::string  filename)

Definition at line 238 of file Configuration.cpp.

template<typename T >
T castor::Configuration::tryGet ( d,
const char *  path,
  ... 
) [inline]

Definition at line 255 of file Configuration.h.

template<typename T >
boost::shared_ptr<std::vector<T> > castor::Configuration::tryGetAll ( d,
const char *  path,
  ... 
) [inline]

Definition at line 271 of file Configuration.h.

boost::shared_ptr< std::vector< std::string > > castor::Configuration::tryGetNames ( std::string  d,
const char *  path,
  ... 
)

Definition at line 430 of file Configuration.cpp.

boost::shared_ptr< std::vector< std::string > > castor::Configuration::tryGetSections ( std::string  d,
const char *  path,
  ... 
)

Definition at line 404 of file Configuration.cpp.


Member Data Documentation

Definition at line 174 of file Configuration.h.

std::string castor::Configuration::filename [protected]

Definition at line 172 of file Configuration.h.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


Castor
Author(s): Carpe Noctem
autogenerated on Fri Nov 8 2013 11:05:41