wood burning stoves 2.0*
The moose likes Struts and the fly likes Domain Object as Strtus Action form. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Domain Object as Strtus Action form. " Watch "Domain Object as Strtus Action form. " New topic
Author

Domain Object as Strtus Action form.

Jigar Naik
Ranch Hand

Joined: Dec 12, 2006
Posts: 753
Hi,

Can we create Struts action form without extending ActionForm class ?

I want to use Domain Object as an action form of struts.


Jigar Naik


Shankar Tanikella
Ranch Hand

Joined: Jan 30, 2011
Posts: 329

No, we can't. A simple example or way to look into it - while you submit your request, struts does the all required processing to set the request content in the corresponding form (your) which extends the ActionForm. In the action classes what you get(known by the method signature) is main/parent type(generic form, the ActionForm) and not the our actual domain form. And to me this is one of the reason or drawback why 1.x is let down


Have Fun with Java
little,little.. little by little makes a lot..
 
jQuery in Action, 2nd edition
 
subject: Domain Object as Strtus Action form.
 
Similar Threads
Form Variables vs Session Variables
Populating <html:select> tag
Passing object to Execute method
struts vs spring framework
Getting Param values from JSP tp servlet