Fimbulwinter Project  Pre-Alpha
An Ragnarok Online Emulator
Classes | Public Member Functions | Static Public Member Functions | Protected Types | Static Protected Member Functions | Protected Attributes | Friends
config_file Class Reference

List of all members.

Classes

struct  file_not_found
struct  key_not_found

Public Member Functions

 config_file (string filename, string delimiter="=", string comment="#", string sentry="EndConfigFile")
template<class T >
read (const string &key) const
template<class T >
read (const string &key, const T &value) const
template<class T >
bool read_into (T &var, const string &key) const
template<class T >
bool read_into (T &var, const string &key, const T &value) const
template<class T >
void add (string key, const T &value)
void remove (const string &key)
bool key_exists (const string &key) const
string get_delimiter () const
string get_comment () const
string get_sentry () const
string set_delimiter (const string &s)
string set_comment (const string &s)

Static Public Member Functions

static void trim (string &s)

Protected Types

typedef std::map< string,
string >::iterator 
mapi
typedef std::map< string,
string >::const_iterator 
mapci

Static Protected Member Functions

template<class T >
static string T_as_string (const T &t)
template<class T >
static T string_as_T (const string &s)

Protected Attributes

string delimiter_
string comment_
string sentry_
std::map< string, string > contents_

Friends

std::ostream & operator<< (std::ostream &os, const config_file &cf)
std::istream & operator>> (std::istream &is, config_file &cf)

The documentation for this class was generated from the following files:
 All Classes Functions