HTML and CSS Reference
In-Depth Information
public boolean isNewEntryFirstTime() {
...
}
public AddressBookEntry getEntry() {
return this.entry;
}
}
Listing 5-20. flowScope Can Be Used to Store Any Kind of Object During the Flow
<!DOCTYPE html>
<html xmlns=" http://www.w3.org/1999/xhtml "
xmlns:h=" http://xmlns.jcp.org/jsf/html " >
<head>
<title>Enter your name</title>
</head>
<body>
<h:form>
<h:outputLabel for="firstName" value="First name: " />
<h:inputText id="firstName" value=" #{flowScope.firstName} " />
<h:outputLabel for="LastName" value="Last name: " />
<h:inputText id="lastName" value=" #{flowScope.lastName} " />
<h:commandButton value="Next" action="contactDetails" />
<h:commandButton value="Cancel" action="cancel" />
</h:form>
</body>
</html>
Packaging
The flow resources can either reside inside your web application in a directory under the web root as shown in
Listing 5-21, or it can be packaged in a JAR file that is then placed in /WEB-INF/lib as shown in Listing 5-22. The page
author does not need to worry about how the flow resources are packaged with the application. Flow resources are
referenced the same regardless of how they are packaged.
Listing 5-21. File Layout of Several Flows Residing Inside the Web Application
| newEntryFlow/newEntryFlow-flow.xml
| newEntryFlow/newEntryHelp.xhtml
| newEntryFlow/create-entry-1.xhtml
| newEntryFlow/create-entry-2.xhtml
| newEntryFlow/create-entry-3.xhtml
| modifyEntryFlow/modifyEntryFlow-flow.xml
| modifyEntryFlow/modifyEntryHelp.xhtml
| modifyEntryFlow/modify-entry-1.xhtml
| modifyEntryFlow/modify-entry-2.xhtml
| modifyEntryFlow/modify-entry-3.xhtml
 
Search WWH ::




Custom Search