Public Member Functions | |
ConfigWizardPanel () throws IOException | |
void | checkAndForward () |
void | doForward () |
void | back () |
String | getHelpContext () |
Container | getCurrentPage () |
int | getState () |
void | finish () |
void | addChangeListener (ChangeListener cl) |
void | removeChangeListener (ChangeListener cl) |
void | stateChanged (ChangeEvent e) |
Vector< String > | check () |
int | getCurrentPageNr () |
int | getPageCount () |
MixConfigPanel | getPage (int a_number) |
Container | getHelpExtractionDisplayContext () |
Static Public Attributes | |
static final int | STATE_GO = 0 |
static final int | STATE_BEGIN = 1 |
static final int | STATE_END = 2 |
static final int | STATE_STOP = 4 |
static final int | STATE_FINISHED = 8 | STATE_BEGIN | STATE_END |
static final int | STATE_READY_TO_FINISH = STATE_END | STATE_GO |
Protected Member Functions | |
void | fireStateChanged () |
int | getNewState () |
void | load () |
void | reset () |
void | setConfiguration (MixConfiguration m) throws IOException |
Private Member Functions | |
void | checkState () |
Private Attributes | |
int | m_currentPage = 0 |
CardLayout | m_layout = new CardLayout(4, 4) |
MixConfigPanel | m_pages [] |
Vector< ChangeListener > | m_changeListener = new Vector<ChangeListener>() |
int | m_state = STATE_BEGIN |
String[] | m_errors = new String[0] |
mixconfig.wizard.ConfigWizardPanel.ConfigWizardPanel | ( | ) | throws IOException |
Constructs a new instance of ConfigWizardPanel
IOException | If an I/O exception occurs while setting the configuration object |
References mixconfig.wizard.ConfigWizardPanel.m_layout, mixconfig.wizard.ConfigWizardPanel.m_pages, mixconfig.wizard.ConfigWizardPanel.m_state, mixconfig.wizard.ConfigWizardPanel.setConfiguration(), and mixconfig.wizard.ConfigWizardPanel.STATE_BEGIN.
void mixconfig.wizard.ConfigWizardPanel.checkAndForward | ( | ) |
Navigate one page forward in the wizard
References mixconfig.wizard.ConfigWizardPanel.checkState(), mixconfig.wizard.ConfigWizardPanel.doForward(), mixconfig.wizard.ConfigWizardPanel.m_errors, mixconfig.wizard.ConfigWizardPanel.m_state, mixconfig.wizard.ConfigWizardPanel.STATE_END, and mixconfig.wizard.ConfigWizardPanel.STATE_STOP.
Referenced by mixconfig.wizard.ConfigWizard.actionPerformed(), and mixconfig.wizard.ConfigWizardPanel.doForward().
void mixconfig.wizard.ConfigWizardPanel.doForward | ( | ) |
Navigate forward without checking for errors
References mixconfig.wizard.ConfigWizardPanel.checkAndForward(), mixconfig.wizard.ConfigWizardPanel.fireStateChanged(), mixconfig.wizard.ConfigWizardPanel.m_currentPage, mixconfig.wizard.ConfigWizardPanel.m_layout, and mixconfig.wizard.ConfigWizardPanel.m_pages.
Referenced by mixconfig.wizard.ConfigWizard.actionPerformed(), and mixconfig.wizard.ConfigWizardPanel.checkAndForward().
void mixconfig.wizard.ConfigWizardPanel.back | ( | ) |
Navigate one page backwards in the wizard
References mixconfig.wizard.ConfigWizardPanel.checkState(), mixconfig.wizard.ConfigWizardPanel.fireStateChanged(), mixconfig.wizard.ConfigWizardPanel.m_currentPage, mixconfig.wizard.ConfigWizardPanel.m_errors, mixconfig.wizard.ConfigWizardPanel.m_layout, mixconfig.wizard.ConfigWizardPanel.m_pages, mixconfig.wizard.ConfigWizardPanel.m_state, and mixconfig.wizard.ConfigWizardPanel.STATE_BEGIN.
Referenced by mixconfig.wizard.ConfigWizard.actionPerformed(), and mixconfig.wizard.ConfigWizardPanel.load().
String mixconfig.wizard.ConfigWizardPanel.getHelpContext | ( | ) |
References mixconfig.wizard.ConfigWizardPanel.m_currentPage, and mixconfig.wizard.ConfigWizardPanel.m_pages.
Referenced by mixconfig.wizard.ConfigWizard.getHelpContext().
Container mixconfig.wizard.ConfigWizardPanel.getCurrentPage | ( | ) |
Gets the current page of the wizard.
References mixconfig.wizard.ConfigWizardPanel.m_currentPage, and mixconfig.wizard.ConfigWizardPanel.m_pages.
Referenced by mixconfig.wizard.ConfigWizard.getCurrentPageClass().
int mixconfig.wizard.ConfigWizardPanel.getState | ( | ) |
Gets the current state of the wizard. This method also calls checkState().
References mixconfig.wizard.ConfigWizardPanel.checkState(), and mixconfig.wizard.ConfigWizardPanel.m_state.
Referenced by mixconfig.wizard.ConfigWizard.actionPerformed().
void mixconfig.wizard.ConfigWizardPanel.finish | ( | ) |
Finishes the wizard. The object that is displaying this wizard should call this method when it wants this wizard to conclude and perform the operation that it has prepared.
This implementation sets the state to STATE_FINISHED and calls fireStateChanged().
Subclasses should override this method to implement their own way of finishing the wizard. The overridden method should call this method, or set the wizard's state to STATE_FINISHED and call fireStateChanged().
References mixconfig.wizard.ConfigWizardPanel.fireStateChanged(), mixconfig.wizard.ConfigWizardPanel.m_state, and mixconfig.wizard.ConfigWizardPanel.STATE_BEGIN.
Referenced by mixconfig.wizard.ConfigWizard.actionPerformed().
void mixconfig.wizard.ConfigWizardPanel.addChangeListener | ( | ChangeListener | cl | ) |
Adds a ChageListener to receive ChangeEvents.
cl | the ChangeListener to be added |
References mixconfig.wizard.ConfigWizardPanel.m_changeListener.
Referenced by mixconfig.wizard.ConfigWizard.ConfigWizard().
void mixconfig.wizard.ConfigWizardPanel.removeChangeListener | ( | ChangeListener | cl | ) |
Removes the specified ChageListener from the list of ChangeListeners registered with this component.
cl | the ChangeListener to be removed |
References mixconfig.wizard.ConfigWizardPanel.m_changeListener.
void mixconfig.wizard.ConfigWizardPanel.stateChanged | ( | ChangeEvent | e | ) |
Called when the state of this wizard changes. This implementation calls fireStateChanged() to re-cast the event.
e | a ChangeEvent |
References mixconfig.wizard.ConfigWizardPanel.fireStateChanged().
Referenced by mixconfig.wizard.ConfigWizardPanel.fireStateChanged().
Vector<String> mixconfig.wizard.ConfigWizardPanel.check | ( | ) |
void mixconfig.wizard.ConfigWizardPanel.fireStateChanged | ( | ) | [protected] |
Notifies all ChangeListeners registered with this object that this object's state has changed.
References mixconfig.wizard.ConfigWizardPanel.m_changeListener, and mixconfig.wizard.ConfigWizardPanel.stateChanged().
Referenced by mixconfig.wizard.ConfigWizardPanel.back(), mixconfig.wizard.ConfigWizardPanel.checkState(), mixconfig.wizard.ConfigWizardPanel.doForward(), mixconfig.wizard.ConfigWizardPanel.finish(), and mixconfig.wizard.ConfigWizardPanel.stateChanged().
int mixconfig.wizard.ConfigWizardPanel.getNewState | ( | ) | [protected] |
Get the altered state of the wizard; this method is needed by checkState() and should be overridden by subclasses of this class.
References mixconfig.panels.MixConfigPanel.check(), mixconfig.wizard.ConfigWizardPanel.m_currentPage, mixconfig.wizard.ConfigWizardPanel.m_errors, mixconfig.wizard.ConfigWizardPanel.m_pages, mixconfig.wizard.ConfigWizardPanel.STATE_BEGIN, mixconfig.wizard.ConfigWizardPanel.STATE_END, mixconfig.wizard.ConfigWizardPanel.STATE_GO, mixconfig.wizard.ConfigWizardPanel.STATE_READY_TO_FINISH, and mixconfig.wizard.ConfigWizardPanel.STATE_STOP.
Referenced by mixconfig.wizard.ConfigWizardPanel.checkState().
void mixconfig.wizard.ConfigWizardPanel.load | ( | ) | [protected] |
Calls the load-method of each Panel This is necessary if you change the view (expert|wizard)
References mixconfig.wizard.ConfigWizardPanel.back(), mixconfig.wizard.ConfigWizardPanel.getCurrentPageNr(), mixconfig.panels.MixConfigPanel.load(), and mixconfig.wizard.ConfigWizardPanel.m_pages.
Referenced by mixconfig.wizard.ConfigWizard.load().
void mixconfig.wizard.ConfigWizardPanel.reset | ( | ) | [protected] |
Set the panel to first leaf
References mixconfig.wizard.ConfigWizardPanel.m_currentPage, mixconfig.wizard.ConfigWizardPanel.m_layout, mixconfig.wizard.ConfigWizardPanel.m_state, and mixconfig.wizard.ConfigWizardPanel.STATE_BEGIN.
Referenced by mixconfig.wizard.ConfigWizard.reset().
void mixconfig.wizard.ConfigWizardPanel.checkState | ( | ) | [private] |
Check whether the state of the wizard has changed, e.g. when a user entered data on a page.
References mixconfig.wizard.ConfigWizardPanel.fireStateChanged(), mixconfig.wizard.ConfigWizardPanel.getNewState(), and mixconfig.wizard.ConfigWizardPanel.m_state.
Referenced by mixconfig.wizard.ConfigWizardPanel.back(), mixconfig.wizard.ConfigWizardPanel.checkAndForward(), and mixconfig.wizard.ConfigWizardPanel.getState().
void mixconfig.wizard.ConfigWizardPanel.setConfiguration | ( | MixConfiguration | m | ) | throws IOException [protected] |
Set the specified configuration object. If the object is null
, the object returned by mixconfig.MixConfig.getMixConfiguration()
is set instead.
This method will also call the setConfiguration(MixConfiguration)
method of all contained mixconfig.MixConfigPanel
instances.
m | A MixConfiguration object to be edited in the wizard |
IOException | If an I/O error occurs while setting the configuration |
References mixconfig.wizard.ConfigWizardPanel.m_pages.
Referenced by mixconfig.wizard.ConfigWizardPanel.ConfigWizardPanel(), and mixconfig.wizard.ConfigWizard.setConfiguration().
int mixconfig.wizard.ConfigWizardPanel.getCurrentPageNr | ( | ) |
Get the current page number within the wizard
References mixconfig.wizard.ConfigWizardPanel.m_currentPage.
Referenced by mixconfig.wizard.ConfigWizard.getCurrentPageNr(), and mixconfig.wizard.ConfigWizardPanel.load().
int mixconfig.wizard.ConfigWizardPanel.getPageCount | ( | ) |
Get the total amount of pages in this wizard
References mixconfig.wizard.ConfigWizardPanel.m_pages.
Referenced by mixconfig.wizard.ConfigWizard.getPageCount().
MixConfigPanel mixconfig.wizard.ConfigWizardPanel.getPage | ( | int | a_number | ) |
References mixconfig.wizard.ConfigWizardPanel.m_pages.
Container mixconfig.wizard.ConfigWizardPanel.getHelpExtractionDisplayContext | ( | ) |
final int mixconfig.wizard.ConfigWizardPanel.STATE_GO = 0 [static] |
indicates a state in which the wizard may continue to the next page
Referenced by mixconfig.wizard.ConfigWizardPanel.getNewState().
final int mixconfig.wizard.ConfigWizardPanel.STATE_BEGIN = 1 [static] |
indicates that the wizard is at the first page
Referenced by mixconfig.wizard.ConfigWizardPanel.back(), mixconfig.wizard.ConfigWizardPanel.ConfigWizardPanel(), mixconfig.wizard.ConfigWizardPanel.finish(), mixconfig.wizard.ConfigWizardPanel.getNewState(), and mixconfig.wizard.ConfigWizardPanel.reset().
final int mixconfig.wizard.ConfigWizardPanel.STATE_END = 2 [static] |
indicates that the wizard is at the last page
Referenced by mixconfig.wizard.ConfigWizardPanel.checkAndForward(), and mixconfig.wizard.ConfigWizardPanel.getNewState().
final int mixconfig.wizard.ConfigWizardPanel.STATE_STOP = 4 [static] |
indicates that the wizard cannot continue to the next page
Referenced by mixconfig.wizard.ConfigWizardPanel.checkAndForward(), and mixconfig.wizard.ConfigWizardPanel.getNewState().
final int mixconfig.wizard.ConfigWizardPanel.STATE_FINISHED = 8 | STATE_BEGIN | STATE_END [static] |
indicates that the wizard is finished
final int mixconfig.wizard.ConfigWizardPanel.STATE_READY_TO_FINISH = STATE_END | STATE_GO [static] |
indicates that the wizard may be finished now
Referenced by mixconfig.wizard.ConfigWizardPanel.getNewState().
int mixconfig.wizard.ConfigWizardPanel.m_currentPage = 0 [private] |
an index indicating the current wizard page
Referenced by mixconfig.wizard.ConfigWizardPanel.back(), mixconfig.wizard.ConfigWizardPanel.doForward(), mixconfig.wizard.ConfigWizardPanel.getCurrentPage(), mixconfig.wizard.ConfigWizardPanel.getCurrentPageNr(), mixconfig.wizard.ConfigWizardPanel.getHelpContext(), mixconfig.wizard.ConfigWizardPanel.getNewState(), and mixconfig.wizard.ConfigWizardPanel.reset().
CardLayout mixconfig.wizard.ConfigWizardPanel.m_layout = new CardLayout(4, 4) [private] |
the layout manager for this container
Referenced by mixconfig.wizard.ConfigWizardPanel.back(), mixconfig.wizard.ConfigWizardPanel.ConfigWizardPanel(), mixconfig.wizard.ConfigWizardPanel.doForward(), and mixconfig.wizard.ConfigWizardPanel.reset().
the pages of this wizard
Referenced by mixconfig.wizard.ConfigWizardPanel.back(), mixconfig.wizard.ConfigWizardPanel.check(), mixconfig.wizard.ConfigWizardPanel.ConfigWizardPanel(), mixconfig.wizard.ConfigWizardPanel.doForward(), mixconfig.wizard.ConfigWizardPanel.getCurrentPage(), mixconfig.wizard.ConfigWizardPanel.getHelpContext(), mixconfig.wizard.ConfigWizardPanel.getNewState(), mixconfig.wizard.ConfigWizardPanel.getPage(), mixconfig.wizard.ConfigWizardPanel.getPageCount(), mixconfig.wizard.ConfigWizardPanel.load(), and mixconfig.wizard.ConfigWizardPanel.setConfiguration().
Vector<ChangeListener> mixconfig.wizard.ConfigWizardPanel.m_changeListener = new Vector<ChangeListener>() [private] |
a ChangeListener
listening to ChangeEvent
s from this object
Referenced by mixconfig.wizard.ConfigWizardPanel.addChangeListener(), mixconfig.wizard.ConfigWizardPanel.fireStateChanged(), and mixconfig.wizard.ConfigWizardPanel.removeChangeListener().
int mixconfig.wizard.ConfigWizardPanel.m_state = STATE_BEGIN [private] |
the current state of the wizard
Referenced by mixconfig.wizard.ConfigWizardPanel.back(), mixconfig.wizard.ConfigWizardPanel.checkAndForward(), mixconfig.wizard.ConfigWizardPanel.checkState(), mixconfig.wizard.ConfigWizardPanel.ConfigWizardPanel(), mixconfig.wizard.ConfigWizardPanel.finish(), mixconfig.wizard.ConfigWizardPanel.getState(), and mixconfig.wizard.ConfigWizardPanel.reset().
String [] mixconfig.wizard.ConfigWizardPanel.m_errors = new String[0] [private] |
An array of strings containing possible error messages
Referenced by mixconfig.wizard.ConfigWizardPanel.back(), mixconfig.wizard.ConfigWizardPanel.checkAndForward(), and mixconfig.wizard.ConfigWizardPanel.getNewState().