Re: [ot] help on generics...

2007-09-28 Thread nicolas de loof
c T getOpt() { >//needs a class object! >T opt = composite. getFeature(); > return opt; >} > } > > Hope this helps. > -Original Message- > From: nicolas de loof [mailto:[EMAIL PROTECTED] > Sent: September 28,

RE: [ot] help on generics...

2007-09-28 Thread Engelking, Nicholas
object! T opt = composite. getFeature(); return opt; } } Hope this helps. -Original Message- From: nicolas de loof [mailto:[EMAIL PROTECTED] Sent: September 28, 2007 4:54 AM To: Struts Users Mailing List Subject: Re: [ot] help on generics... T

Re: [ot] help on generics...

2007-09-28 Thread nicolas de loof
created with the > constructor parameters passed. If the constructor throws an error it is > wrapped in an InvocationTargetException and rethrown. If no constructor > matches the method returns null. > > > -Original Message- > From: Giovanni Azua [mailto:[EMAIL PROTECTED

RE: [ot] help on generics...

2007-09-27 Thread Engelking, Nicholas
ationTargetException and rethrown. If no constructor matches the method returns null. -Original Message- From: Giovanni Azua [mailto:[EMAIL PROTECTED] Sent: September 27, 2007 11:56 AM To: Struts Users Mailing List Subject: Re: [ot] help on generics... how about: public static T getI

Re: [ot] help on generics...

2007-09-27 Thread Giovanni Azua
how about: public static T getInstance(Class aClass) { // TODO: } regards, Giovanni nicolas de loof wrote: Hello, my question is fully off topic, but Struts2 is the only java5 project I know. I'd like a method to return an instance of a class passed as parameter : public Object getInst