StocksMonitor 1.5.0

hirondelle.stocks.preferences
Interface PreferencesEditor

All Known Implementing Classes:
GeneralLookPreferencesEditor, LoggingPreferencesEditor, QuoteTablePreferencesEditor

public interface PreferencesEditor

Allows editing of a set of related user preferences.

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.


Method Summary
 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.
 

Method Detail

getUI

JComponent getUI()
Return a GUI component which allows the user to edit this set of related preferences.


getTitle

String getTitle()
The name of the tab in which this PreferencesEditor will be placed.


getMnemonic

int getMnemonic()
The mnemonic to appear in the tab name.

Must match a letter appearing in getTitle(). Use constants defined in KeyEvent, for example KeyEvent.VK_A.


savePreferences

void savePreferences()
Store the related preferences as they are currently displayed, overwriting all corresponding settings.


matchGuiToDefaultPreferences

void matchGuiToDefaultPreferences()
Reset the related preferences to their default values, but only as presented in the GUI, without affecting stored preference values.

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.


StocksMonitor 1.5.0

Copyright Hirondelle Systems - License - Generated 2008Jul12.10.53