Re: #ServiceLoaderEnhancements

2016-09-15 Thread Alex Buckley
Best to wait for the spec. On 9/15/2016 12:34 PM, Peter Levart wrote: On 09/15/2016 05:51 PM, Alan Bateman wrote: On 15/09/2016 07:54, Peter Levart wrote: One thing that is not clear is whether the yyy in "provides xxx with yyy" directive of module declaration must be a concrete class and a

Re: #ServiceLoaderEnhancements

2016-09-15 Thread Peter Levart
On 09/15/2016 05:51 PM, Alan Bateman wrote: On 15/09/2016 07:54, Peter Levart wrote: One thing that is not clear is whether the yyy in "provides xxx with yyy" directive of module declaration must be a concrete class and a subtype of service type when the service is obtained via a static

Re: #ServiceLoaderEnhancements

2016-09-15 Thread Alan Bateman
On 15/09/2016 07:54, Peter Levart wrote: One thing that is not clear is whether the yyy in "provides xxx with yyy" directive of module declaration must be a concrete class and a subtype of service type when the service is obtained via a static method. For example, is the following a valid

Re: #ServiceLoaderEnhancements

2016-09-15 Thread Peter Levart
Hi, Reading number (2) of the proposal... the static provider() method (declared by "provider class") and returning a "provider object" sounds confusing when coupled with number (3) which proposes a ServiceLoader.Provider interface. Should Provider interface be renamed to ProviderFactory?

Re: Proposal: #ServiceLoaderEnhancements

2016-09-13 Thread Stephen Colebourne
On 13 September 2016 at 21:04, wrote: > 2016/9/12 15:08:41 -0700, Stephen Colebourne : >> My preference of these three options is option 2. > > Sorry if I wasn't clear, but this isn't meant to be a "choose one" > proposal. It's a set of check

Re: Proposal: #ServiceLoaderEnhancements

2016-09-13 Thread mark . reinhold
2016/9/12 15:08:41 -0700, Stephen Colebourne : > My preference of these three options is option 2. Sorry if I wasn't clear, but this isn't meant to be a "choose one" proposal. It's a set of check boxes, not radio buttons. The proposal is to implement suggestions (2) and

Re: Proposal: #ServiceLoaderEnhancements

2016-09-12 Thread Stephen Colebourne
k Reinhold <mark.reinh...@oracle.com> wrote: > Issue summary > - > > #ServiceLoaderEnhancements --- The module system encourages the use of > services for loose coupling, but the `ServiceLoader` class is not very > flexible. Consider enhancing it so that (1