Java Reference
In-Depth Information
/**
* @param beanValue the beanValue to set
*/
public void setBeanValue(String beanValue) {
this.beanValue = beanValue;
}
}
A standard JSF command component can be used to enter a flow, specifying the flow name for the action.
For instance, if you want to use a link to enter into a flow named exampleFlow , you can do something like
the following:
<h:commandLink value="Enter flow" action="exampleFlow" />
Specifying the flow name for the action works because the flow has the same name as the folder containing the
flow view nodes, so the action simply causes navigation to that folder. As mentioned previously, by convention,
the first view node within the flow should have the same name as the enclosing folder. Using this convention causes
the first view node within the flow to be accessed when specifying the flow name as the action for a command
component. The code below shows what the exampleFlow.xhtml view contains.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
" http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd " >
<html xmlns=" http://www.w3.org/1999/xhtml "
xmlns:f=" http://xmlns.jcp.org/jsf/core "
xmlns:h=" http://xmlns.jcp.org/jsf/html "
xmlns:ui=" http://xmlns.jcp.org/jsf/facelets " >
<h:head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<title>Faces Flow Example #1, Page 1</title>
</h:head>
<h:body>
<ui:composition template="../layout/custom_template.xhtml">
<ui:define name="content">
<h:form prependId="false">
<p>
This is the first view of the flow.
<br/>
Is this page contained within the flow? #{null
!= facescontext.application.flowHandler.currentFlow}
<br/>
Message: #{flowBean.beanValue}
<br/><br/>
<h:commandLink value="Go to another view in the flow" action=ā€¯intermediateFlow"/>
</p>
</h:form>
 
Search WWH ::




Custom Search