|
The JSF application contains one or more backing bean. A Backing Bean is simple Java Bean class used to hold the data coming from the form elements to the server in some structured format. It is a normal bean class with getter/setter specified for all the properties of the form. The following are the steps to add the bean support in the JSF application:-
Step 1:-Creating the Bean Class.
The following RegistrationBean.java class created for the registration.jsp
package com.visualbuilder;
public class RegistrationBean { private String name; private String password; private String password1; private String description;
public String getDescription() { return description; }
public String getName() { return name; }
public String getPassword() { return password; }
public void setDescription(String description) { this.description = description; }
public void setName(String name) { this.name = name; }
public void setPassword(String password) { this.password = password; }
public void setPassword1(String password1) { this.password1 = password1; }
public String getPassword1() { return password1; } } |