struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mark Galbreath" <mark_galbre...@qat.com>
Subject RE: Design of action classes
Date Tue, 14 Jan 2003 14:02:02 GMT
I think the consensus is to use one Action class per Action form (bean).
For a simple update like you describe, it would be natural for the same
Action to update the database (actually, call a DAO or EJB) whether it's a
new user or new information for an existing user.  Work through your use
cases and I think it will become apparent what Action classes are
appropriate for specific responsibilities.

Mark

-----Original Message-----
From: João Paulo Batistella [mailto:batistellabr@yahoo.com.br] 
Sent: Tuesday, January 14, 2003 8:36 AM

We are deciding about how to use action classes in our project.

Is it a problem to let developers use the same action class to handle
different operations?

Example:

The action UpdateUserAction could be used to insert a new user or to update
the data of an existing user. Is it a problem? Or it's better to have
InsertUserAction and SaveUserAction. They do almost the same thing so I
think they could be same.

Thanks,

Joao Paulo.



--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>


Mime
View raw message