com.borland.primetime.wizard
Interface WizardHost


public interface WizardHost

The WizardHost interface defines the host for a Wizard session. The Wizard can call back into the WizardHost to get the Browser context, set the 'Next' and "Finish' buttons enabled/disabled, as well as changing the total number of steps for the wizard on the fly as a user selects a different path through the wizard. The WizardHost also supplies access to a parent dialog for use when a Wizard wishes to display a model dialog.

See Also:
Wizard

Method Summary
 Browser getBrowser()
          Returns the Browser instance that the hosted Wizard was launched from.
 java.awt.Dialog getDialogParent()
          Returns the Dialog to use as a Parent for any pop-up dialogs.
 void setFinishEnabled(boolean enabled)
          Sets the 'Finish' button enabled or disabled in the WizardHost.
 void setNextEnabled(boolean enabled)
          Sets the 'Next' button enabled or disabled in the WizardHost.
 void setTotalSteps(int count)
          Sets the total number of steps for the Wizard.
 

Method Detail

getBrowser

public Browser getBrowser()
Returns the Browser instance that the hosted Wizard was launched from.
Returns:
The Browser instance that the hosted Wizard was launched from.

getDialogParent

public java.awt.Dialog getDialogParent()
Returns the Dialog to use as a Parent for any pop-up dialogs.
Returns:
The Dialog to use as a Parent for any pop-up dialogs.

setTotalSteps

public void setTotalSteps(int count)
Sets the total number of steps for the Wizard. This method can be called at any time, so the total number of steps can change while the user is manipulating controls on any page.
Parameters:
count - The new total number of steps for the Wizard. If the passed value is less than the current step number, an InvalidArgumentException is thrown.

setNextEnabled

public void setNextEnabled(boolean enabled)
Sets the 'Next' button enabled or disabled in the WizardHost. Use this method to restrict the user moving forward in the Wizard until all required values are filled in. By default, the 'Next' button is enabled until the last step of the Wizard is displayed.
Parameters:
enabled - True to enable the 'Next' button, false to disable it.

setFinishEnabled

public void setFinishEnabled(boolean enabled)
Sets the 'Finish' button enabled or disabled in the WizardHost. Use this method to allow the user to finish the Wizard early - when you can assume defaults for the rest of the steps in the Wizard. By default, the 'Finish' button is disabled until the last step of the Wizard is displayed.
Parameters:
enabled - True to enable the 'Finish' button, false to disable it.