Great idea.

El Lunes, 31 de Julio de 2006 10:50, Russell, Paul escribió:
> This does kind of feel like the kind of thing that could lead to scenario
> explosion; I'm sure there are all sorts of policies that different
> companies have implemented. Would it be better to have an SPI for it?
> Something like the following contributed to a configuration point:
>
> public interface ServiceImplementationLocator {
>       /** Attempt to discover a service implementation for a service
>        * implementing serviceInterface
>        * @return the implementation class for the service, or null if
>        *      one could not be determined automatically.
>        */
>       public Class discoverServiceImplementation(Class serviceInterface);
> }
>
> Just a thought,
>
>
> Paul
>
> -----Original Message-----
> From: Pablo Lalloni [mailto:[EMAIL PROTECTED]
> Sent: 31 July 2006 14:47
> To: dev@hivemind.apache.org
> Cc: James Carman
> Subject: Re: New convention?
>
> El Lunes, 31 de Julio de 2006 07:49, James Carman escribió:
> > Yes, *Impl in the same package might even be the first place it looks.
> > Then look for an *Impl in the impl subpackage.  I normally use the latter
> > setup, but many folks do just put the implementation classes in the same
> > package as their interface.  I'd like to make HiveMind very simple to
> > configure with minimal effort.  That's why we offer the option to use
> > "convention over configuration."
>
> In cases when there will be just a single impl or a "default" one for a
> given
> service we just make it a static inner class of the service interface.
>
> public interface SomeService {
>   ...
>   public static class Default implements SomeService {
>     ...
>   }
> }
>
> So if the impl "search path" includes this idiom, it would be great for us
> as
> this is definitely the most frequent case here.

-- 
Pablo I. Lalloni <[EMAIL PROTECTED]>

[EMAIL PROTECTED] · ICQ#6322141 · [EMAIL PROTECTED]

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Quid me anxius sum?

[ What? Me, worry? ]

Reply via email to