public interface PreferencesEditor
Implementations of this interface do not define a "stand-alone" GUI, but rather a component (usually a JPanel) which can be used by the caller in any way they want. Typically, a set of PreferencesEditor objects are placed in a JTabbedPane, one per pane.
Modifier and Type | Method and Description |
---|---|
int |
getMnemonic()
The mnemonic to appear in the tab name.
|
String |
getTitle()
The name of the tab in which this PreferencesEditor
will be placed.
|
JComponent |
getUI()
Return a GUI component which allows the user to edit this set of related
preferences.
|
void |
matchGuiToDefaultPreferences()
Reset the related preferences to their default values, but only as
presented in the GUI, without affecting stored preference values.
|
void |
savePreferences()
Store the related preferences as they are currently displayed, overwriting
all corresponding settings.
|
JComponent getUI()
int getMnemonic()
Must match a letter appearing in getTitle()
.
Use constants defined in KeyEvent, for example KeyEvent.VK_A.
void savePreferences()
void matchGuiToDefaultPreferences()
This method may not apply in all cases. For example, if the item represents a config which has no meaningful default value (such as a mail server name), the desired behavior may be to only allow a manual change. In such a case, the implementation of this method must be a no-operation.
Copyright Hirondelle Systems - License - Generated 2013Sep20.10.58