net.javaprog.ui.wizard
Interface WizardModel

All Known Implementing Classes:
DefaultWizardModel

public interface WizardModel

Models a sequence of steps.

See Also:
Step, WizardModelListener

Method Summary
 void addWizardModelListener(WizardModelListener l)
          Adds a listener for the back, next and finish actions.
 void cancelWizard()
          Cancels the wizard.
 boolean contains(Step step)
          Returns whether the sequence contains the given step.
 void finishWizard()
          Finishes the wizard if possible.
 int getCurrentIndex()
          Returns the index of the currently visible step in the sequence.
 Step getCurrentStep()
          Returns the currently visible step.
 int getStepCount()
          Returns the number of steps in this sequence.
 Step[] getSteps()
          Returns the sequence of steps as a plain array.
 void goBack()
          Requests that the previous step should be shown if possible.
 void goNext()
          Requests that the next step should be shown if possible.
 void removeWizardModelListener(WizardModelListener l)
          Removes a previously added listener.
 

Method Detail

addWizardModelListener

public void addWizardModelListener(WizardModelListener l)
Adds a listener for the back, next and finish actions.


removeWizardModelListener

public void removeWizardModelListener(WizardModelListener l)
Removes a previously added listener.


getCurrentStep

public Step getCurrentStep()
Returns the currently visible step.


getCurrentIndex

public int getCurrentIndex()
Returns the index of the currently visible step in the sequence.


contains

public boolean contains(Step step)
Returns whether the sequence contains the given step.


getSteps

public Step[] getSteps()
Returns the sequence of steps as a plain array.


getStepCount

public int getStepCount()
Returns the number of steps in this sequence.


goNext

public void goNext()
Requests that the next step should be shown if possible. This method must notify the registered WizardListeners of the request.


goBack

public void goBack()
Requests that the previous step should be shown if possible. This method must notify the registered WizardListeners of the request.


cancelWizard

public void cancelWizard()
Cancels the wizard. This method must notify the registered WizardListeners of the cancel event.


finishWizard

public void finishWizard()
Finishes the wizard if possible. This method must notify the registered WizardListeners of the finish event.