webuijsf
Tag wizardStep


Use the webuijsf:wizardStep tag to define a single step of a wizard.

In a simple wizard, the webuijsf:wizardStep tag is a child of the webuijsf:wizard tag. In a branching wizard, the webuijsf:wizardStep tag can be used as a child of the webuijsf:wizardBranchSteps tag or webuijsf:wizardSubstepBranch tag.

HTML Elements and Layout

The only HTML element that is rendered specifically for the WizardStep component is <webuijsf:markup tag="div" styleClass="#{themeStyles.WIZARD_TASK}">.  The WizTsk class selector is not defined by the suntheme or the defaulttheme, so the <div> uses default rendering. The <div> contains the HTML that is rendered for the child tags that are contained in the webuijsf:wizardStep tag.

The values that are specified in the summary and help attributes are displayed in the Steps tab and Help tab. The title value is displayed in the Step Title area, and the detail value is displayed in the Step Instructions area in the Step Content pane. The input components, labels, and so on that you specify as child components in the webuijsf:wizardStep are displayed in the Step Input Controls area in the Step Content pane. See the webuijsf:wizard documentation for a detailed description of all the wizard areas.

The following diagram shows the relative location of the wizardStep areas. The areas that are controlled with the webuijsf:wizardStep tag are highlighted in light blue. The grayed out areas are controlled with the webuijsf:wizard tag, but are shown here for context.

Wizard Title 
Steps Pane
Steps Tab






Help Tab
Step Content Pane
Step Title 
Step Instructions
Step Input Controls


Navigation Controls                    


Using the webuijsf:wizardStep Tag

Use the webuijsf:wizardStep tag attributes to provide information about the step, such as the title, summary, detail, and help. These attributes are used in the wizard layout as described in the previous section.

The finish attribute is used to indicate that the Navigation Controls area of the step should contain a Finish button that will execute the wizard task when clicked.

The results attribute is used to indicate that the step is a View Results page, which should contain a Close button in the Navigation Controls area. A View Results page comes after the Finish page, and is used to summarize the work that the wizard has performed, and lists any actions users should take after closing the wizard.

The webuijsf:wizardStep tag also provides attributes (onCancel, onClose, etc.) for specifying client-side JavaScript to be executed when the user clicks on the various buttons and tabs. These attributes take precedence over similar attributes in the webuijsf:wizard tag. For example, if the onNext attribute is specified in both the webuijsf:wizard and webuijsf:wizardStep tags, only the JavaScript assigned to the webuijsf:wizardStep tag's onNext attribute is applied to the rendered Next button. However, for any steps in the wizard that do not specify the onNext attribute, the webuijsf:wizard tag's onNext attribute would be used.

The eventListener attribute is used to specify an event listener for the step, which is executed as the user leaves the step and the form is submitted. See the Event Listeners section in the wizard tag documentation for more information.

Within the webuijsf:wizardStep tag, specify the tags for child components such as webuijsf:staticText, webuijsf:textField, webuijsf:checkbox, webuijsf:radioButton, and webuijsf:dropDown to create the content of the step.

You can specify the content tags in a step in either of the following ways:

The <f:subview> tag in step1.jsp contains:

  <f:subview id=sv_step1>
     
...
     
<webuijsf:textField id="name" ... />
     
<webuijsf:textField id="address" ... />
      ...
  /f:subview>

Wizard Steps in a Branch

A wizard uses a branch when the sequence of steps is determined by the user's input. For example, the wizard can allow a user to choose one of two options, and that choice causes the wizard to proceed through one sequence of steps. If the user chooses the other option, the wizard proceeds through a different sequence.

Note that you might be able to avoid branching, and simplify the wizard, if you can structure your application so that the user's choice is made before launching the wizard. You can use the user's choice to launch a different wizard to present each sequence of steps, which would require only the webuijsf:wizard and webuijsf:wizardStep tags.

See the webuijsf:wizardBranchSteps documentation and webuijsf:wizardSubstepBranch documentation for more information about how to implement branching. The webuijsf:wizardStep tag can be used a child of these branching tags, to create the steps in the branching sequence.

Client-side JavaScript Functions

None.

Examples

See the webuijsf:wizard tag example for a simple wizard. See the webuijsf:wizardBranch tag example for a more complex wizard that uses branching.



Tag Information
Tag Classcom.sun.webui.jsf.component.WizardStepTag
TagExtraInfo ClassNone
Body ContentJSP
Display NameNone

Attributes
NameRequiredRequest-timeTypeDescription
bindingfalsefalsejava.lang.String A ValueExpression that resolves to the UIComponent that corresponds to this tag. This attribute allows the Java bean that contains the UIComponent to manipulate the UIComponent, its properties, and its children.
summaryfalsefalsejava.lang.String A brief description of this step, to be used in the numbered list of steps in the Steps pane.
onCancelfalsefalsejava.lang.String Scripting code executed when the Cancel button is clicked.
titlefalsefalsejava.lang.String A descriptive title to be displayed as the Step Title in the Step Content pane. The Step Title consists of the step number followed by the value of the title attribute. The value of the title attribute could be the same as the value of the summary attribute, or could provide a more detailed description.
detailfalsefalsejava.lang.String The detail attribute supplies the text that is to be displayed in the Step Instructions area, before the input components of the Step Content pane. Typically you would provide one or two sentences that describe what the step does, or tell the user how to interact with the step.
onFinishfalsefalsejava.lang.String Scripting code executed when the Finish button is clicked.
onNextfalsefalsejava.lang.String Scripting code executed when the Next button is clicked.
onStepLinkfalsefalsejava.lang.String Scripting code executed when a Step link is clicked.
idfalsetruejava.lang.StringNo Description
onClosefalsefalsejava.lang.String Scripting code executed when the Close button is clicked.
resultsfalsefalsejava.lang.String Set the results attribute to true when the wizard step represents the View Results page. This page should be used after the wizard task is completed, to display information related to the task, including failure information if appropriate. This attribute causes the Close button to be displayed on the View Results page.
helpfalsefalsejava.lang.String Descriptive text that provides detailed help to the user for this step. The amount of text specified is unlimited but is typically only a few short paragraphs. The content can contain HTML markup for formatting. Note that you must use the character entity references &lt; and &gt; to create the < and > characters for HTML elements in the help text.
onHelpTabfalsefalsejava.lang.String Scripting code executed when the Help tab is clicked.
finishfalsefalsejava.lang.String Set the finish attribute to true when the wizard step represents the Finish step. For wizards with three or more steps, the Finish step should be the Review Selections page. The finish attribute causes the Finish button to be displayed. The Finish step performs the wizard task when the user clicks the Finish button.
eventListenerfalsefalsejava.lang.String The eventListener attribute is used to specify an object to handle an event that is triggered when a user activates a component in the step. The eventListener attribute value must be a JavaServer Faces EL expression that resolves to an instance of com.sun.webui.jsf.event.WizardEventListener.

The return value of the wizard component's call to the event listener's handleEvent() method controls the processing of the current step, and determines whether the next step or a previous step, etc. can be navigated to.

See the Event Listeners section in the webuijsf:wizard tag documentation for more information.

onStepsTabfalsefalsejava.lang.String Scripting code executed when the Steps tab is clicked.
onPreviousfalsefalsejava.lang.String Scripting code executed when the Next button is clicked.

Variables
No Variables Defined.


Output Generated by Tag Library Documentation Generator. Java, JSP, and JavaServer Pages are trademarks or registered trademarks of Sun Microsystems, Inc. in the US and other countries. Copyright 2002-4 Sun Microsystems, Inc. 4150 Network Circle Santa Clara, CA 95054, U.S.A. All Rights Reserved.