DMTClientConfig Class Reference
[Sync Client]

This class is an extension of SyncManagerConfig that is DM tree aware; this means that configuration properties are read/stored from/to the DM tree. More...

#include <DMTClientConfig.h>

Inheritance diagram for DMTClientConfig:

Inheritance graph
[legend]
Collaboration diagram for DMTClientConfig:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 DMTClientConfig (const char *root) EXTRA_SECTION_01
SyncSourceConfiggetSyncSourceConfig (const char *name, BOOL refresh=FALSE) EXTRA_SECTION_01
SyncSourceConfiggetSyncSourceConfig (unsigned int i, BOOL refresh=FALSE) EXTRA_SECTION_01
virtual BOOL read () EXTRA_SECTION_01
virtual BOOL save () EXTRA_SECTION_01
virtual BOOL open () EXTRA_SECTION_01
 Opens the configuration backend associated with the root context.
virtual ManagementNode * getSyncMLNode () EXTRA_SECTION_01
 Provides access to the "syncml" configuration node, can be used to read/write custom configuration options.
virtual int getNumSources () EXTRA_SECTION_01
 Gets number of sync source configurations, -1 if not open.
virtual ManagementNode * getSyncSourceNode (int index) EXTRA_SECTION_01
 Get the specified sync source configuration.
virtual ManagementNode * getSyncSourceNode (const char *name) EXTRA_SECTION_01
 Get the specified sync source configuration by name.
virtual void close () EXTRA_SECTION_01
 Closes the configuration backend.

Protected Member Functions

void initialize ()
virtual BOOL readAccessConfig (ManagementNode &n) EXTRA_SECTION_01
virtual void saveAccessConfig (ManagementNode &n) EXTRA_SECTION_01
virtual BOOL readDeviceConfig (ManagementNode &n) EXTRA_SECTION_01
virtual void saveDeviceConfig (ManagementNode &n) EXTRA_SECTION_01
virtual BOOL readSourceConfig (int i, ManagementNode &n) EXTRA_SECTION_01
virtual void saveSourceConfig (int i, ManagementNode &n) EXTRA_SECTION_01
virtual BOOL readAuthConfig (ManagementNode &syncMLNode, ManagementNode &authNode) EXTRA_SECTION_01
 Called by readAccessConfig() to save authentication settings.
virtual void saveAuthConfig (ManagementNode &syncMLNode, ManagementNode &authNode) EXTRA_SECTION_01
 Same as readAccessConfig() for saving the settings.
virtual BOOL readConnConfig (ManagementNode &syncMLNode, ManagementNode &connNode) EXTRA_SECTION_01
 Same as readAccessConfig() for reading connection information.
virtual void saveConnConfig (ManagementNode &syncMLNode, ManagementNode &connNode) EXTRA_SECTION_01
 Same as readAccessConfig() for saving connection information.
virtual BOOL readExtAccessConfig (ManagementNode &syncMLNode, ManagementNode &extNode) EXTRA_SECTION_01
 Same as readAccessConfig() for reading additional access information.
virtual void saveExtAccessConfig (ManagementNode &syncMLNode, ManagementNode &extNode) EXTRA_SECTION_01
 Same as readAccessConfig() for saving additional access information.
virtual BOOL readDevInfoConfig (ManagementNode &syncMLNode, ManagementNode &devInfoNode) EXTRA_SECTION_01
 Same as readAccessConfig() for reading device information.
virtual void saveDevInfoConfig (ManagementNode &syncMLNode, ManagementNode &devInfoNode) EXTRA_SECTION_01
 Same as readAccessConfig() for saving device information.
virtual BOOL readDevDetailConfig (ManagementNode &syncMLNode, ManagementNode &devDetailNode) EXTRA_SECTION_01
 Same as readAccessConfig() for reading additional device information.
virtual void saveDevDetailConfig (ManagementNode &syncMLNode, ManagementNode &devDetailNode) EXTRA_SECTION_01
 Same as readAccessConfig() for saving additional device information.
virtual BOOL readExtDevConfig (ManagementNode &syncMLNode, ManagementNode &extNode) EXTRA_SECTION_01
 Same as readAccessConfig() for reading some more additional device information.
virtual void saveExtDevConfig (ManagementNode &syncMLNode, ManagementNode &extNode) EXTRA_SECTION_01
 Same as readAccessConfig() for saving some more additional device information.
virtual BOOL readSourceVars (int i, ManagementNode &sourcesNode, ManagementNode &sourceNode)
 Same as readAccessConfig() for reading variables that the library uses internally, like anchors.
virtual void saveSourceVars (int i, ManagementNode &sourcesNode, ManagementNode &sourceNode)
 Same as readAccessConfig() for saveing variables that the library uses internally, like anchors.
virtual BOOL readSourceConfig (int i, ManagementNode &sourcesNode, ManagementNode &sourceNode)
 Same as readAccessConfig() for reading the normal properties of a sync source, i.e.
virtual void saveSourceConfig (int i, ManagementNode &sourcesNode, ManagementNode &sourceNode)
 Same as readAccessConfig() for reading the normal properties of a sync source, i.e.

Protected Attributes

char * rootContext
DMTree * dmt
ManagementNode * syncMLNode
ManagementNode * sourcesNode

Detailed Description

This class is an extension of SyncManagerConfig that is DM tree aware; this means that configuration properties are read/stored from/to the DM tree.

Todo:
describe the properties of the DM tree and how they are grouped into device info, additional device info, extended device info, etc.


Member Function Documentation

virtual BOOL DMTClientConfig::readAuthConfig ( ManagementNode &  syncMLNode,
ManagementNode &  authNode 
) [protected, virtual]

Called by readAccessConfig() to save authentication settings.

The purpose of making this function virtual is that a derived class can override it and then to read the settings from a different than the default "spds/syncml/auth" node by calling the base function with a different authNode parameter or generate the settings in some other way.

Parameters:
syncMLNode the "spds/syncml" node
authNode the "spds/syncml/auth" node

virtual void DMTClientConfig::saveAuthConfig ( ManagementNode &  syncMLNode,
ManagementNode &  authNode 
) [protected, virtual]

Same as readAccessConfig() for saving the settings.

Parameters:
syncMLNode the "spds/syncml" node
authNode the "spds/syncml/auth" node

virtual BOOL DMTClientConfig::readConnConfig ( ManagementNode &  syncMLNode,
ManagementNode &  connNode 
) [protected, virtual]

Same as readAccessConfig() for reading connection information.

Parameters:
syncMLNode the "spds/syncml" node
connNode the "spds/syncml/conn" node

virtual void DMTClientConfig::saveConnConfig ( ManagementNode &  syncMLNode,
ManagementNode &  connNode 
) [protected, virtual]

Same as readAccessConfig() for saving connection information.

Parameters:
syncMLNode the "spds/syncml" node
connNode the "spds/syncml/conn" node

virtual BOOL DMTClientConfig::readExtAccessConfig ( ManagementNode &  syncMLNode,
ManagementNode &  extNode 
) [protected, virtual]

Same as readAccessConfig() for reading additional access information.

Parameters:
syncMLNode the "spds/syncml" node
extNode the "spds/syncml/ext" node

virtual void DMTClientConfig::saveExtAccessConfig ( ManagementNode &  syncMLNode,
ManagementNode &  extNode 
) [protected, virtual]

Same as readAccessConfig() for saving additional access information.

Parameters:
syncMLNode the "spds/syncml" node
extNode the "spds/syncml/ext" node

virtual BOOL DMTClientConfig::readDevInfoConfig ( ManagementNode &  syncMLNode,
ManagementNode &  devInfoNode 
) [protected, virtual]

Same as readAccessConfig() for reading device information.

Parameters:
syncMLNode the "spds/syncml" node
devInfoNode the "spds/syncml/devinfo" node

virtual void DMTClientConfig::saveDevInfoConfig ( ManagementNode &  syncMLNode,
ManagementNode &  devInfoNode 
) [protected, virtual]

Same as readAccessConfig() for saving device information.

Parameters:
syncMLNode the "spds/syncml" node
devInfoNode the "spds/syncml/devinfo" node

virtual BOOL DMTClientConfig::readDevDetailConfig ( ManagementNode &  syncMLNode,
ManagementNode &  devDetailNode 
) [protected, virtual]

Same as readAccessConfig() for reading additional device information.

Parameters:
syncMLNode the "spds/syncml" node
devDetailNode the "spds/syncml/devdetail" node

virtual void DMTClientConfig::saveDevDetailConfig ( ManagementNode &  syncMLNode,
ManagementNode &  devDetailNode 
) [protected, virtual]

Same as readAccessConfig() for saving additional device information.

Parameters:
syncMLNode the "spds/syncml" node
devDetailNode the "spds/syncml/devdetail" node

virtual BOOL DMTClientConfig::readExtDevConfig ( ManagementNode &  syncMLNode,
ManagementNode &  extNode 
) [protected, virtual]

Same as readAccessConfig() for reading some more additional device information.

Parameters:
syncMLNode the "spds/syncml" node
extNode the "spds/syncml/ext" node

virtual void DMTClientConfig::saveExtDevConfig ( ManagementNode &  syncMLNode,
ManagementNode &  extNode 
) [protected, virtual]

Same as readAccessConfig() for saving some more additional device information.

Parameters:
syncMLNode the "spds/syncml" node
extNode the "spds/syncml/ext" node

virtual BOOL DMTClientConfig::readSourceVars ( int  i,
ManagementNode &  sourcesNode,
ManagementNode &  sourceNode 
) [protected, virtual]

Same as readAccessConfig() for reading variables that the library uses internally, like anchors.

Parameters:
i index of the source
sourcesNode the "spds/sources" node
sourceNode the "spds/sources/<source name>" node

virtual void DMTClientConfig::saveSourceVars ( int  i,
ManagementNode &  sourcesNode,
ManagementNode &  sourceNode 
) [protected, virtual]

Same as readAccessConfig() for saveing variables that the library uses internally, like anchors.

Parameters:
i index of the source
sourcesNode the "spds/sources" node
sourceNode the "spds/sources/<source name>" node

virtual BOOL DMTClientConfig::readSourceConfig ( int  i,
ManagementNode &  sourcesNode,
ManagementNode &  sourceNode 
) [protected, virtual]

Same as readAccessConfig() for reading the normal properties of a sync source, i.e.

excluding variables like anchors.

Parameters:
i index of the source
sourcesNode the "spds/sources" node
sourceNode the "spds/sources/<source name>" node

virtual void DMTClientConfig::saveSourceConfig ( int  i,
ManagementNode &  sourcesNode,
ManagementNode &  sourceNode 
) [protected, virtual]

Same as readAccessConfig() for reading the normal properties of a sync source, i.e.

excluding variables like anchors.

Parameters:
i index of the source
sourcesNode the "spds/sources" node
sourceNode the "spds/sources/<source name>" node

virtual BOOL DMTClientConfig::open (  )  [virtual]

Opens the configuration backend associated with the root context.

Calling on an open config does nothing.

Returns:
TRUE for success

virtual ManagementNode* DMTClientConfig::getSyncMLNode (  )  [virtual]

Provides access to the "syncml" configuration node, can be used to read/write custom configuration options.

Config must have been opened before.

Returns:
node pointer owned by config and valid while the config is open

virtual ManagementNode* DMTClientConfig::getSyncSourceNode ( int  index  )  [virtual]

Get the specified sync source configuration.

Parameters:
index number of the requested sync source configuration
Returns:
node pointer owned by config and valid while the config is open

virtual void DMTClientConfig::close (  )  [virtual]

Closes the configuration backend.

Frees all resources associated with and invalidates all ManagementNode pointers returned by this config.


The documentation for this class was generated from the following file:
Generated on Fri Apr 27 12:29:21 2007 for Funambol C++ Client Library by  doxygen 1.5.2