Re: [picocontainer-dev] annotations and comments on Pico2

Konstantin Priblouda <kpriblouda-/[email protected]>
Newsgroups gmane.comp.java.picocontainer.devel
Message-ID <[email protected]>
--- Paul Hammant <[email protected]> wrote:

> Pico2 supports an @Inject annotation.  Its from our
> own package  
> hierarchy, but we recommend against using it.  
> Someone could extend  
> the functionality of the AnnotationComponentFactory
> class to support  
> Guice's (or any other Domain's if that's their
> choice) annotation types.
> We recommend against using it because we don't think
> components  
> should be scarred by any
> classes/interfaces/exceptions from the  
> container world. We have a Startable interface that
> breaks that  
> design, but we have no choice really as there's
> nothing in the JDK  
> for that.  Its extendable too for someone else's
> Startable concept.
> 
> Its easy for us to have a ComponentFactory that
> looks for @Singleton  
> on classes, or @ThreadLocal and does the right
> thing.  There are no  
> new apis needed for MutablePicoContainer.
> 
> I think most people's hopes for annotations can be
> met in their own  
> domain model and some modest extending of
> ComponentFactory classes  
> from our codebase.  Pico is all about facilitating
> choices without  
> creating lock-in (we hope).

we could provide some base class with overridable 
injection decision points so users can bolt on their
own annotation types.

this way users get a choice what lock-in they prefer. 

regards,


----[ Konstantin Pribluda http://www.pribluda.de ]----------------
JTec quality components: http://www.pribluda.de/projects/


       
____________________________________________________________________________________
Got a little couch potato? 
Check out fun summer activities for kids.
http://search.yahoo.com/search?fr=oni_on_mail&p=summer+activities+for+kids&cs=bz 

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.