RE: Reusing methods across actions classes

2004-09-30 Thread fzlists
Writing your own Action class that extends Action and then extending that to make each class is an option. Depending on the nature of your shared code, it might be easier to just make an "ActionHelpers" class that contains a bunch of methods, maybe a bunch of static methods even, depending on

Re: Reusing methods across actions classes

2004-09-30 Thread Sean Schofield
It may also depend on what kind of code you are trying to reuse. If its something that is action-related (populating a form, etc.) then I would agree with Danilo's answer. If on the other hand, the code is related to business logic that is really independent of the struts portion, then I would

RE: Reusing methods across actions classes

2004-09-30 Thread Danilo Gurovich
Why don't you just create an abstract action and extend it? Danilo Gurovich Manager, Web Development LowerMyBills.com [EMAIL PROTECTED] 2401 Colorado Ave., 2nd Floor Santa Monica, CA 90404 (310) 998-6412 -Original Message- From: Ciaran Hanley [mailto:[EMAIL PROTECTED] Sent: Thursday

RE: Reusing methods across actions classes

2004-09-30 Thread Robert Taylor
Thursday, September 30, 2004 6:25 AM > To: 'Struts Users Mailing List'; [EMAIL PROTECTED] > Subject: RE: Reusing methods across actions classes > > > My actions already extend Action. Should I write a superclass that extends > Action, and then extend this class, i

RE: Reusing methods across actions classes

2004-09-30 Thread Prasenjit Narwade
Probably you can create a Generic Action class which extends Struts Action class and make all your Action classes extend this class. You can then put the reusable methods in this class and it can be used by all your Action classes. -Prasenjit -Original Message- From: Ciaran Hanley [mailt

RE: Reusing methods across actions classes

2004-09-30 Thread Mark Benussi
ts Users Mailing List'" <[EMAIL PROTECTED]>,<[EMAIL PROTECTED]> Subject: RE: Reusing methods across actions classes Date: Thu, 30 Sep 2004 11:25:25 +0100 My actions already extend Action. Should I write a superclass that extends Action, and then extend this class, is that correc

RE: Reusing methods across actions classes

2004-09-30 Thread Ciaran Hanley
: Reusing methods across actions classes I would say that if you have common functionality such as a method that all objects [Actions] share then place the common method in a super class [Action] that the other classes can extend. Original Message Follows From: "Ciaran Hanley&quo

RE: Reusing methods across actions classes

2004-09-30 Thread Mark Benussi
I would say that if you have common functionality such as a method that all objects [Actions] share then place the common method in a super class [Action] that the other classes can extend. Original Message Follows From: "Ciaran Hanley" <[EMAIL PROTECTED]> Reply-To: "Struts Users Mailing