KDECore
KConfigGroup Class Reference
A KConfigBase derived class for one specific group in a KConfig object. More...
#include <kconfigbase.h>
Public Member Functions | |
void | deleteGroup (bool bGlobal=false) |
bool | groupIsImmutable () const |
KConfigGroup (KConfigBase *master, const char *group) | |
KConfigGroup (KConfigBase *master, const QString &group) | |
KConfigGroup (KConfigBase *master, const QCString &group) | |
virtual KEntry | lookupData (const KEntryKey &_key) const |
virtual void | putData (const KEntryKey &_key, const KEntry &_data, bool _checkGroup=true) |
virtual void | setDirty (bool _bDirty) |
virtual void | sync () |
Protected Member Functions | |
virtual void | virtual_hook (int id, void *data) |
Detailed Description
A KConfigBase derived class for one specific group in a KConfig object.Definition at line 2101 of file kconfigbase.h.
Constructor & Destructor Documentation
KConfigGroup::KConfigGroup | ( | KConfigBase * | master, | |
const QCString & | group | |||
) |
Construct a config group corresponding to group
in master
.
group
is the group name encoded in UTF-8.
Definition at line 1799 of file kconfigbase.cpp.
KConfigGroup::KConfigGroup | ( | KConfigBase * | master, | |
const QString & | group | |||
) |
This is an overloaded constructor provided for convenience.
It behaves essentially like the above function.
Construct a config group corresponding to group
in master
Definition at line 1786 of file kconfigbase.cpp.
KConfigGroup::KConfigGroup | ( | KConfigBase * | master, | |
const char * | group | |||
) |
This is an overloaded constructor provided for convenience.
It behaves essentially like the above function.
Construct a config group corresponding to group
in master
group
is the group name encoded in UTF-8.
Definition at line 1812 of file kconfigbase.cpp.
Member Function Documentation
void KConfigGroup::deleteGroup | ( | bool | bGlobal = false |
) |
Delete all entries in the entire group.
- Parameters:
-
bGlobal If bGlobal
is true, the entries are not removed from the application specific config file, but from the global KDE config file.
Definition at line 1825 of file kconfigbase.cpp.
bool KConfigGroup::groupIsImmutable | ( | ) | const |
Checks whether it is possible to change this group.
- Returns:
- whether changes may be made to this group in this configuration file.
- Since:
- 3.4
Definition at line 1830 of file kconfigbase.cpp.
Looks up an entry in the config object's internal structure.
Classes that derive from KConfigBase will need to implement this method in a storage-specific manner.
Do not use this function, the implementation and return type are subject to change.
- Parameters:
-
_key The key to look up It contains information both on the group of the key and the entry's key itself.
- Returns:
- The KEntry value (data) found for the key.
KEntry.aValue
will be the null string if nothing was located.
For internal use only.
Implements KConfigBase.
Definition at line 1845 of file kconfigbase.cpp.
void KConfigGroup::putData | ( | const KEntryKey & | _key, | |
const KEntry & | _data, | |||
bool | _checkGroup = true | |||
) | [virtual] |
Inserts a (key/value) pair into the internal storage mechanism of the configuration object.
Classes that derive from KConfigBase will need to implement this method in a storage-specific manner.
Do not use this function, the implementation / return type are subject to change.
- Parameters:
-
_key The key to insert. It contains information both on the group of the key and the key itself. If the key already exists, the old value will be replaced. _data the KEntry that is to be stored. _checkGroup When false, assume that the group already exists.
For internal use only.
Implements KConfigBase.
Definition at line 1840 of file kconfigbase.cpp.
void KConfigGroup::setDirty | ( | bool | _bDirty | ) | [virtual] |
Sets the global dirty flag of the config object.
- Parameters:
-
_bDirty How to mark the object's dirty status
Reimplemented from KConfigBase.
Definition at line 1835 of file kconfigbase.cpp.
void KConfigGroup::sync | ( | ) | [virtual] |
Flushes all changes that currently reside only in memory back to disk / permanent storage.
Dirty configuration entries are written to the most specific file available.
Asks the back end to flush out all pending writes, and then calls rollback(). No changes are made if the object has readOnly
status.
You should call this from your destructor in derivative classes.
- See also:
- rollback(), isReadOnly()
Reimplemented from KConfigBase.
Definition at line 1850 of file kconfigbase.cpp.
void KConfigGroup::virtual_hook | ( | int | id, | |
void * | data | |||
) | [protected, virtual] |
The documentation for this class was generated from the following files: