David Graham wrote:

--- Robert Leland <[EMAIL PROTECTED]> wrote:


David Graham wrote:



--- Robert Leland <[EMAIL PROTECTED]> wrote:




I believe at one time we were going to deprecate ActionErrors since it
is really a shell over ActionMessages. We could still keep the
error tag, just make it use ActionMessages directly.





It would be nice to get rid of it but I don't think we can until 2.0. ActionForm.validate() (and other methods) return an ActionErrors


object.

There is no way to deprecate those methods with a new version that


returns


ActionMessages because return types aren't part of method signatures.

I


think this would break backwards compatibility but I would love to be
wrong on this one :-).



You're right. We could provide a stop gap ActionForm.validateToMsg() or whatever that returns a
list of ActionMessages objects. We could then get rid of ActionError internally by making it a facade
of ActionMessage instead of extending ActionMessage. The same goes for ActionErrors, it would only be a facade.
and only created when needed.



This seems overly complicated. Why not just wait for 2.0 to remove this and replace it with commons-resources classes? At least, that's what I think we were planning.

I think deprecating ActionError is ok because ActionErrors can hold
ActionMessage objects instead.

David

validateToMsg() doesn't have anything to do with resources. validateToMsg() would return an ActionMessages
object instead of an ActionErrors object. I know validateToMsg isn't a good name.
Maybe we just call it something else, maybe verify() or check(). This is similar to what we did for perform() vs
execute(), we gave the users a transition path so they could gradually as needed remove deprecated methods.


-Rob

--
Robert Leland                   [EMAIL PROTECTED]
------------------------------------------
Java, J2EE, Struts, Web Application Development

804 N. Kenmore Street           +01-703-525-3580
Arlington VA 22201



Reply via email to