FileConfigTree Class Reference

#include <FileConfigTree.h>

Inheritance diagram for FileConfigTree:

Inheritance graph
[legend]
Collaboration diagram for FileConfigTree:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 FileConfigTree (const string &root, bool oldLayout)
virtual string getRootPath () const
virtual void flush ()
virtual void reset ()
virtual boost::shared_ptr
< ConfigNode
open (const string &path, PropertyType type, const string &otherId=string(""))
list< string > getChildren (const string &path)


Detailed Description

This implementation maps nodes to plain .ini style files below an absolute directory of the filesystem. The caller is responsible for choosing that directory and how hidden and user-visible files are to be named.

Definition at line 34 of file FileConfigTree.h.


Constructor & Destructor Documentation

FileConfigTree::FileConfigTree ( const string &  root,
bool  oldLayout 
)

Parameters:
root absolute filesystem path
oldLayout use file names as in SyncEvolution <= 0.7

Definition at line 35 of file FileConfigTree.cpp.


Member Function Documentation

void FileConfigTree::flush (  )  [virtual]

ensure that all changes are saved persistently

Implements ConfigTree.

Reimplemented in VolatileConfigTree.

Definition at line 47 of file FileConfigTree.cpp.

list< string > FileConfigTree::getChildren ( const string &  path  )  [virtual]

returns names of all existing nodes beneath the given path

Implements ConfigTree.

Definition at line 105 of file FileConfigTree.cpp.

References normalizePath().

string FileConfigTree::getRootPath (  )  const [virtual]

a string identifying the root of the configuration - exact meaning varies

Implements ConfigTree.

Definition at line 42 of file FileConfigTree.cpp.

References normalizePath().

boost::shared_ptr< ConfigNode > FileConfigTree::open ( const string &  path,
PropertyType  type,
const string &  otherId = string("") 
) [virtual]

Open the specified node. Opening it multiple times will return the same instance, so the content is always synchronized.

Parameters:
path a relative path with / as separator
type selects which fork of that path is to be opened (visible, hidden, change tracking)
otherId an additional string to be attached to the other node's name (allows having multiple different such nodes); an empty string is allowed

Implements ConfigTree.

Definition at line 59 of file FileConfigTree.cpp.

References ConfigTree::hidden, normalizePath(), and ConfigTree::other.

void FileConfigTree::reset (  )  [virtual]

Definition at line 54 of file FileConfigTree.cpp.


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

Generated on Sat Oct 18 17:17:04 2008 for SyncEvolution and Funambol by  doxygen 1.5.7.1