About Question enthuware.ocejws.v6.2.202 :

Moderators: Site Manager, fjwalraven

Post Reply
disznoperzselo
Posts: 28
Joined: Fri Jan 02, 2015 12:13 pm
Contact:

About Question enthuware.ocejws.v6.2.202 :

Post by disznoperzselo »

Isn't it problematic to use "new LocalSub();" in a stateless session bean where
LocalSub is a Singleton?

fjwalraven
Posts: 429
Joined: Tue Jul 24, 2012 2:43 am
Contact:

Re: About Question enthuware.ocejws.v6.2.202 :

Post by fjwalraven »

Yes, good point, I can't think of any practical reason when you want an implementation like this. However it is allowed by the JAX-RS specifications.

Regards,
Frits

sttaq0442
Posts: 27
Joined: Tue Nov 15, 2016 11:20 am
Contact:

Re: About Question enthuware.ocejws.v6.2.202 :

Post by sttaq0442 »

Hi,

If we have a class which implements an interface and extends another class both having annotations then will it ignore ALL the annotations from the interface? or will it keep only those annotations from the interface which are not present in the base class?

Thanks

fjwalraven
Posts: 429
Joined: Tue Jul 24, 2012 2:43 am
Contact:

Re: About Question enthuware.ocejws.v6.2.202 :

Post by fjwalraven »

Good question! (you won't find a tricky one like this because it is ambiguous, the specs are not clear)
If we have a class which implements an interface and extends another class both having annotations then will it ignore ALL the annotations from the interface?
My interpretation of the specs: Yes, but I agree: it has room for a different interpretation...

Regards,
Frits

Post Reply

Who is online

Users browsing this forum: No registered users and 20 guests