|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.kde.koala.KConfigBackEnd
org.kde.koala.KConfigINIBackEnd
public class KConfigINIBackEnd
Class for KDE INI-style configuration file loading/saving.
Constructor Summary | |
---|---|
protected |
KConfigINIBackEnd(java.lang.Class dummy)
|
|
KConfigINIBackEnd(KConfigBase _config,
java.lang.String _fileName,
java.lang.String _resType)
|
|
KConfigINIBackEnd(KConfigBase _config,
java.lang.String _fileName,
java.lang.String _resType,
boolean _useKDEGlobals)
Constructs an ini-style configuration back end. |
Method Summary | |
---|---|
void |
dispose()
Delete the wrapped C++ instance ahead of finalize() |
protected void |
finalize()
Deletes the wrapped C++ instance |
boolean |
isDisposed()
Has the wrapped C++ instance been deleted? |
boolean |
parseConfigFiles()
Parses all INI-style configuration files for a config object. |
protected void |
parseSingleConfigFile(org.kde.qt.QFile rFile)
Parses one configuration file. |
void |
sync()
|
void |
sync(boolean bMerge)
Writes configuration data to file(s). |
protected boolean |
writeConfigFile(java.lang.String filename)
|
protected boolean |
writeConfigFile(java.lang.String filename,
boolean bGlobal)
|
protected boolean |
writeConfigFile(java.lang.String filename,
boolean bGlobal,
boolean bMerge)
Writes configuration file back. |
Methods inherited from class org.kde.koala.KConfigBackEnd |
---|
changeFileName, checkConfigFilesWritable, fileName, getConfigState, resource, setFileWriteMode, setLocaleString |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected KConfigINIBackEnd(java.lang.Class dummy)
public KConfigINIBackEnd(KConfigBase _config, java.lang.String _fileName, java.lang.String _resType, boolean _useKDEGlobals)
_config
- Specifies the configuration object which values
will be passed to as they are read, or from where values
to be written to will be obtained from._fileName
- The name of the file in which config
data is stored. All registered configuration directories
will be looked in in order of decreasing relevance._resType
- the resource type of the fileName specified, _if_
it is not an absolute path (otherwise this parameter is ignored)._useKDEGlobals
- If true, the user's system-wide kdeglobals file
will be imported into the config object. If false, only
the filename specified will be dealt with.public KConfigINIBackEnd(KConfigBase _config, java.lang.String _fileName, java.lang.String _resType)
Method Detail |
---|
public boolean parseConfigFiles()
parseConfigFiles
in class KConfigBackEnd
public void sync(boolean bMerge)
sync
in class KConfigBackEnd
bMerge
- Specifies whether the old config file already
on disk should be merged in with the data in memory. If true,
data is read off the disk and merged. If false, the on-disk
file is removed and only in-memory data is written out.public void sync()
sync
in class KConfigBackEnd
protected void parseSingleConfigFile(org.kde.qt.QFile rFile)
rFile
- The configuration file to parsepWriteBackMap
- If specified, points to a KEntryMap where
the data read from the file should be stored, instead of
inserting them directly into the configuration object.
Use this area as a "scratchpad" when you need to know what is
on disk but don't want to effect the configuration object.bGlobal
- Specifies whether entries should be marked as
belonging to the global KDE configuration file rather
than the application-specific KDE configuration file(s).bDefault
- Specifies whether entries should be marked as
being default values.protected boolean writeConfigFile(java.lang.String filename, boolean bGlobal, boolean bMerge)
filename
- The name of the file to write.bGlobal
- Specifies whether to write only entries which
are marked as belonging to the global KDE config file.
If this is false, it skips those entries.bMerge
- Specifies whether the old config file already
on disk should be merged in with the data in memory. If true,
data is read off the disk and merged. If false, the on-disk
file is removed and only in-memory data is written out.
protected boolean writeConfigFile(java.lang.String filename, boolean bGlobal)
protected boolean writeConfigFile(java.lang.String filename)
protected void finalize() throws java.lang.InternalError
finalize
in class java.lang.Object
java.lang.InternalError
public void dispose()
public boolean isDisposed()
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |