This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Struts and the fly likes Creation of form bean instance Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Creation of form bean instance" Watch "Creation of form bean instance" New topic

Creation of form bean instance

Akshay Singhvi
Ranch Hand

Joined: Nov 08, 2005
Posts: 93
Hello Ranchers,
When is the form bean instance created and is it created just once or always when the data is populated to the form bean.

Regards,<br />Akshay Singhvi<br />SCJP 1.4 (95%)<br />SCWCD 1.4 (86%)
Brent Sterling
Ranch Hand

Joined: Feb 08, 2006
Posts: 948
If you have your action mapping configured to use request scope then a new instance of your action form will be created for each request. If your action mapping is configured to use session scope (the default) then an instance will be created, stored on the session, and reused between requests. In either case, every user would have their own instance.

- Brent
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link:
subject: Creation of form bean instance
jQuery in Action, 3rd edition