com.sas.swing.visuals.wizard
Interface WizardPageInterface

All Known Implementing Classes:
BaseWizardPage, BaseWizardPage, SummaryPage, SummaryPage

public interface WizardPageInterface

WizardPageInterface is an interface used by pages contained in a Wizard. See class BaseWizardPage for an implementation of this interface.

See Also:
Wizard, BaseWizardPage

Field Summary
static int EXPLICIT_SET
          a bit set on a flag passed to a page's showPage and hidePage methods.
static int FIRST_TIME_SHOWN
          a bit set on a flag passed to a page's showPage method, indicating it is the first time this page has been shown.
static int NEXT
          a bit set on a flag passed to a page's showPage and hidePage methods.
static int PREVIOUS
          a bit set on a flag passed to a page's showPage and hidePage methods.
 
Method Summary
 void cleanup()
          Called from Wizard's cleanup method.
 java.lang.String getPageInfo()
          Returns information about this page to be used in the wizard title.
 java.lang.String getStatusImage()
          Returns the source path or URL string for this page's image.
 boolean hidePage(int directionFlag)
          Called whenever the page is traversed away from in the wizard.
 boolean isButtonEnabled(java.lang.String actionCommand)
          Returns a boolean value indicating if the button whose action command is actionCommand is enabled.
 void showPage(int directionFlag)
          Called whenever the page is shown in the wizard.
 

Field Detail

PREVIOUS

static final int PREVIOUS
a bit set on a flag passed to a page's showPage and hidePage methods. In the showPage method, it indicates that the page just traversed away from was the one previous to this one on the path. In the hidePage method, it indicates that the page to be traversed to is the one previous to this one on the path.

See Also:
showPage(int), hidePage(int), Constant Field Values

NEXT

static final int NEXT
a bit set on a flag passed to a page's showPage and hidePage methods. In the showPage method, it indicates that the page just traversed away from was the one directly after this one on the path. In the hidePage method, it indicates that the page to be traversed to is the one directly after this one on the path.

See Also:
showPage(int), hidePage(int), Constant Field Values

FIRST_TIME_SHOWN

static final int FIRST_TIME_SHOWN
a bit set on a flag passed to a page's showPage method, indicating it is the first time this page has been shown.

See Also:
showPage(int), Constant Field Values

EXPLICIT_SET

static final int EXPLICIT_SET
a bit set on a flag passed to a page's showPage and hidePage methods. In the showPage method it indicates this page has been called to be shown explicitly, and not necessarily by the "Back" or "Next" buttons being activated. Therefore, the page just traversed away from may not have been the one previous or next to it in the path.

In the hidePage method it indicates the page to be traversed to has been called to be shown explicitly.

See Also:
showPage(int), Constant Field Values
Method Detail

getPageInfo

java.lang.String getPageInfo()
Returns information about this page to be used in the wizard title. Called from Wizard method getTitle.

Returns:
a String object containing information about this page to be used in the wizard title

isButtonEnabled

boolean isButtonEnabled(java.lang.String actionCommand)
Returns a boolean value indicating if the button whose action command is actionCommand is enabled. Return true if enabled, otherwise false.

Called from ButtonNavigationPanel method enableButtons.

Parameters:
actionCommand - the action command of the button to check
Returns:
a boolean value indicating if the button whose action command is actionCommand is enabled
See Also:
BaseWizardPage, ButtonNavigationPanel

showPage

void showPage(int directionFlag)
Called whenever the page is shown in the wizard.

Parameters:
directionFlag - an integer flag whose bits specify the page that was shown before, relative to this page on the path. Also specifies if it is the first time the page has been shown. Valid values are PREVIOUS, NEXT, or EXPLICIT_SET, in combination with FIRST_TIME_SHOWN, if it is the first time the page has been shown.
See Also:
PREVIOUS, NEXT, FIRST_TIME_SHOWN, EXPLICIT_SET

hidePage

boolean hidePage(int directionFlag)
Called whenever the page is traversed away from in the wizard. Validation code may be placed here. If the validation fails, a value of false could be returned, causing the page not to be hidden. A return value of true allows the page to be hidden.

Parameters:
directionFlag - an integer flag whose bits specify the page that will be shown after this one, relative to this page on the path. Valid values are PREVIOUS, NEXT, or EXPLICIT_SET.
Returns:
a boolean value indicating if the can be hidden.
See Also:
PREVIOUS, NEXT, EXPLICIT_SET

cleanup

void cleanup()
Called from Wizard's cleanup method. Wizard pages may implement this method to release resources such as open connections or files, before the wizard exits.

See Also:
Wizard.cleanup()

getStatusImage

java.lang.String getStatusImage()
Returns the source path or URL string for this page's image. This method is called every time a Wizard page is shown. The default Wizard image may be returned by calling Wizard method getDefaultImage, or another source path or URL string for the page's image may be returned.

If the desired behavior is to have no image associated with the page, allowing the page to take up the entire space in the Wizard deckAndImagePanel, then this method should return null.

Returns:
a String representing the source path or URL string for the page's image



Copyright © 2009 SAS Institute Inc. All Rights Reserved.