org.xwiki.gwt.user.client.ui.wizard
Class AbstractNavigationAwareWizardStep

java.lang.Object
  extended by org.xwiki.gwt.user.client.ui.wizard.AbstractNavigationAwareWizardStep
All Implemented Interfaces:
WizardStep
Direct Known Subclasses:
AbstractAutoSubmitWizardStep, AbstractInteractiveWizardStep

public abstract class AbstractNavigationAwareWizardStep
extends Object
implements WizardStep

An abstract wizard step that is aware of the wizard navigation.

Version:
$Id$

Constructor Summary
AbstractNavigationAwareWizardStep()
           
 
Method Summary
 String getDirectionName(NavigationListener.NavigationDirection direction)
          Allows this step to overwrite the default printed for the navigation directions.
 String getNextStep()
          Returns the key of the next step in the wizard.
 EnumSet<NavigationListener.NavigationDirection> getValidDirections()
          
 String setDirectionName(NavigationListener.NavigationDirection direction, String name)
          Sets the name for a navigation direction.
 void setNextStep(String nextStep)
          Sets the name of the next wizard step.
 void setValidDirections(EnumSet<NavigationListener.NavigationDirection> validDirections)
          Sets the valid directions the wizard can go to from this wizard step.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.xwiki.gwt.user.client.ui.wizard.WizardStep
display, getResult, getStepTitle, init, isAutoSubmit, onCancel, onSubmit
 

Constructor Detail

AbstractNavigationAwareWizardStep

public AbstractNavigationAwareWizardStep()
Method Detail

getDirectionName

public String getDirectionName(NavigationListener.NavigationDirection direction)
Allows this step to overwrite the default printed for the navigation directions.

Specified by:
getDirectionName in interface WizardStep
Parameters:
direction - the direction to get the name for
Returns:
the String with the direction name or null if the default should be kept
See Also:
WizardStep#getDirectionName(NavigationDirection)

setDirectionName

public String setDirectionName(NavigationListener.NavigationDirection direction,
                               String name)
Sets the name for a navigation direction.

Parameters:
direction - a wizard navigation direction
name - a string that will be used on the UI to indicate the specified direction
Returns:
the previous name associated with the given direction

getNextStep

public String getNextStep()
Returns the key of the next step in the wizard. Note that this function is called after WizardStep.onSubmit(AsyncCallback) has returned successfully, so the computing of the next step can be done safely at WizardStep.onSubmit(AsyncCallback) time.

Specified by:
getNextStep in interface WizardStep
Returns:
the key of the next step in the wizard
See Also:
WizardStep.getNextStep()

setNextStep

public void setNextStep(String nextStep)
Sets the name of the next wizard step.

Parameters:
nextStep - the name of the next wizard step

getValidDirections

public EnumSet<NavigationListener.NavigationDirection> getValidDirections()

Specified by:
getValidDirections in interface WizardStep
Returns:
the set of valid directions from this step
See Also:
WizardStep.getValidDirections()

setValidDirections

public void setValidDirections(EnumSet<NavigationListener.NavigationDirection> validDirections)
Sets the valid directions the wizard can go to from this wizard step.

Parameters:
validDirections - the valid directions the wizard can go to from this wizard step


Copyright © 2004-2011 XWiki. All Rights Reserved.