struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Syed Ibrahim" <>
Subject RE: Using ActionForm in struts2
Date Fri, 30 Mar 2007 09:49:19 GMT

Thanks a Lot!

-----Original Message-----
From: Dave Newton [] 
Sent: Friday, March 30, 2007 2:36 PM
To: Struts Users Mailing List
Subject: Re: Using ActionForm in struts2

--- Syed Ibrahim <> wrote:
> Instead of writing the getter and setters in Action
> I would prefer then to be written separately as the 
> same bean can  be used elsewhere in models or
> DAO transfer objects. 
> How to achieve that in Struts 2 ?

Write your POJO, expose it in your action per JavaBean
spec, and use it in your form? Pseudo:

class Action Foo {
    private User user; // Plus getter and setter.

  <s:textfield name="user.fname".../>


Get your own web address.  
Have a HUGE year through Yahoo! Small Business.

To unsubscribe, e-mail:
For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message