> -----Original Message----- > From: Marco Tedone [mailto:[EMAIL PROTECTED] > Sent: Tuesday, September 07, 2004 7:40 AM > To: Struts Users Mailing List > Subject: Re: A couple of questions > > > > > There are many. First, when you use an ActionForm you can mine the > > values of request parameters from multiple requests. > > In the kind of applications we write this is not an issue. > Additionally, it > seems to me > that when put in the 'session' scope, there will only be one > ActionForm > object for
If you put it into session scope, then you only have threading issues if you allow a single user to invoke more then one thread in a session. The way to avoid that is to use the request scope. > a given form, with 'threading-related' issues (I'm thinking > of reset(), for > instance). Which > would be the advantage of having information stored in an > ActionForm object > stored in > the session, against, for instance, a value object stored in > the session? > However, I can > understand that for some applications this may be usefull. With a value object, int, float double and any other non-string violates a common assumption with UI's. When a user types in an invalid value for a field, they generally expect the invalid data to be returned as the the user typed it in... Writing the code to do this is certaily possible, and you're probably doing... but why write code you have to maintain? > > So, while you seem > > to be doing the same thing with [ActionForm].getParameter() as with > > request.getParameter("parameter") you definitely are NOT. > You are in > > fact abstracting the request.getParameter("parameter") > method call so > > that you don't have to keep repeating it, > > Well, you still need to perform a call on the ActionForm > object, even if > this > is unique. > > i.e. you get rid of > > unnecessary, repetitive, coding. Second, if there are validations > > issues, as you have seen, they are also abstracted. > > This could be an advantage for some applications, but the > cost of creating > an ActionForm > is still too high for us. > > Third, you get a > > whole panoply of tags which are tied to the ActionForm and allow > > simplified work with page design. > > For the major part, we use JSTL. However, I wanted to ask a > question here: > could we use only the struts-html tag library, without declaring > ActionForms? > This would be very usefull for internationalization. > > Fourth, you get to set the form on the > > page in relation to your model with an ease that is a bit > surprising. > > Could you please elaborate this? > > > > This is a poplular framework because it definitely is a good design. > > Craig did one hell of a job on this. > > > > Michael > > > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]