class KSimpleConfig

KDE Configuration Management class. More...

Definition#include <ksimpleconfig.h>
InheritsKConfigBase
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

Public Methods

Protected Methods


Detailed Description

KDE Configuration entries

This is a trivial implementation of KConfigBase for applications that need only one configuration file and no default system.

See also: getConfig, KConfigBase, KConfig

void  parseConfigFiles ()

[protected virtual]

Open all appropriate configuration files and pass them on to parseOneConfigFile()

Reimplemented from KConfigBase

 KSimpleConfig ( const char* pFile )

Construct a read-write KSimpleConfig object.

Parameters:
pfileThe file used for saving the config data.

 KSimpleConfig ( const char* pFile, bool bReadOnly )

Construct a KSimpleConfig object and make it either read-write or read-only.

Parameters:
pFileThe file uses for saving the config data. bReadOnly Whether the object should be read-only.

KSimpleConfig ()

[virtual]

Destructor.

Writes back any dirty configuration entries.

bool  isReadOnly ()

[const]

Returns true if the object is read-only

void  sync ()

[virtual]

Write back the cache.

Reimplemented from KConfigBase

bool  writeConfigFile ( QFile& rFile, bool bGlobal = false )

Write back the configuration data.

Reimplemented from KConfigBase

const QString  deleteEntry ( const char* pKey, bool bLocalized )

Delete a configuration entry.

Parameters:
pKeyThe key of the entry to delete
bLocalizedWhether the localized or the non-localized key should be deleted

Returns: The old value of that key.

bool  deleteGroup ( const char* pGroup, bool bDeep = true )

Delete a configuration entry group

If the group is not empty and bDeep is false, nothing gets deleted and false is returned. If this group is the current group and it is deleted, the current group is undefined and should be set with setGroup() before the next operation on the configuration object.

Parameters:
pGroupThe name of the group
bDeepWhether non-empty groups should be completely deleted (including their entries)

Returns: If the group does not exist or is not empty and bDeep is false, deleteGroup returns false.