users@concurrency-ee-spec.java.net

[jsr236-spec users] [jsr236-experts] Re: Question on ContextService javadoc

From: Nathan Rauh <naterauh_at_us.ibm.com>
Date: Tue, 19 Mar 2013 17:12:38 -0500

Anthony,

I don't know the original reason, but I agree the requirement for an
accessible default constructor doesn't make any sense and ought to be
removed.

Nathan Rauh
____________________________________________
Software Engineer, WebSphere Application Server
IBM Rochester Bldg 002-2 C111
3605 Highway 52N
Rochester, MN 55901-7802



From: Anthony Lai <anthony.lai_at_oracle.com>
To: jsr236-experts_at_concurrency-ee-spec.java.net
Date: 03/19/2013 04:59 PM
Subject: [jsr236-experts] Question on ContextService javadoc



In the createContextualProxy methods in ContextService, we have the
following in the javadoc:

Throws:
IllegalArgumentException - - if the interfaces argument is null, the
instance does not implement all the specified interfaces, or there is not
an accessible default constructor.


I cannot recall why we need to throw an IllegalArgumentException when
there is not an accessible default constructor in the object that we want
to create a contextual object proxy for. Does anyone remember the reason
why? If not, I am planning to rewrite it to:

    IllegalArgumentException - - if the interfaces argument is null or the
instance does not implement all the specified interfaces.

Regards
Anthony