You now create a Java bean, which is associated with the view that you have just created.
A bean is used to separate the business logic from the presentation logic, and a bean is simply an instance of a class. This class contains the information that will be displayed in the JSP view.
In this tutorial, at run time, the dispatching servlet binds an appropriate bean to the attribute "book" before calling the JSP. For example, in the book.stockno variable that was created previously in the JSP file, the JSP invokes the getStockno method on BookBean, and inserts the return value into the JSP output.