|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.mozdev.MacroTracker.toolkit.registry.MRegistry
public class MRegistry
This is basically a system registry clone from Windows. It holds settings for your program and they are outputted to a data file.
Every time you save a new setting, it is saved to the registry file taken in through the constructor.
Constructor Summary | |
---|---|
MRegistry(java.io.File file)
Creates a new registry using the file taken in through the constructor. |
|
MRegistry(java.lang.String fileName)
|
Method Summary | |
---|---|
java.lang.Object |
getSetting(java.lang.String name)
Returns a certain setting from the registry. |
void |
saveSetting(java.lang.String name,
java.lang.Object data)
Saves a setting to the registry. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MRegistry(java.lang.String fileName)
fileName
- The name of the file to save with the registry settings.public MRegistry(java.io.File file)
If the file exists at that spot, its settings are loaded into the registry. If it does not exist, a new one is created.
Method Detail |
---|
public void saveSetting(java.lang.String name, java.lang.Object data)
If the setting already exists, it's overridden.
name
- The name of the setting in the registry.data
- The information to contain in that setting.public java.lang.Object getSetting(java.lang.String name)
name
- The name of the setting to retrieve.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |