Paulo Gaspar wrote:
>>...but Map does allow potentially more efficient implementations.
>>
> 
> For efficiency:
> 
>   interface ServiceManager
>   {
>      Object lookup( Object key );
>      boolean hasService( Object key );
>      void release( Object key );
>   }
> 
> IMO this provides the most efficient basic implementation and 
> maximum flexibility.

It might allow too much flexibility. AIU, the contract surrounding 
ServiceManager is basically:

   MyThing mt = (MyThing) sm.lookup("com.things.MyThing");

I don't really see a way to express this with Object keys.

(: A ;)



--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to