These patches from sept/03 add support for multiple constructors. See MultipleConstructorTestCase. I tagged both the pico and nano CVSes before making the patches. The name of the tag is BEFORE_MULTIPLE_CONSTRUCTORS.
The approach is described here: http://lists.codehaus.org/pipermail/picocontainer-dev/2003-August/001009.html
While doing this, several new refactorings became apparent, notably:
o Lazy instantiation (PICO-6). PicoContainer.initializeComponents() is gone, because instantiation now happens lazily as components are asked for.
o ComponentRegistry has less knowledge of the components and delegates more functionality to ComponentAdapter.
o PicoContainer.getComponent(Object) throws PicoInitializationException (because of the laziness).
o Introduction of a new InstanceComponentAdapter, used for constant parameters and externally instantiated components.
o And various smaller things
All tests are green. Code coverage has dropped to 88.8%, but this is mostly due to dead code that hasn't yet been removed. Coverage will be back as soon as I do some more cleaning.
It would be nice to have this applied quickly.
These patches from sept/03 add support for multiple constructors. See MultipleConstructorTestCase. I tagged both the pico and nano CVSes before making the patches. The name of the tag is BEFORE_MULTIPLE_CONSTRUCTORS.
The approach is described here: http://lists.codehaus.org/pipermail/picocontainer-dev/2003-August/001009.html
While doing this, several new refactorings became apparent, notably:
o Lazy instantiation (
PICO-6). PicoContainer.initializeComponents() is gone, because instantiation now happens lazily as components are asked for.o ComponentRegistry has less knowledge of the components and delegates more functionality to ComponentAdapter.
o PicoContainer.getComponent(Object) throws PicoInitializationException (because of the laziness).
o Introduction of a new InstanceComponentAdapter, used for constant parameters and externally instantiated components.
o And various smaller things
All tests are green. Code coverage has dropped to 88.8%, but this is mostly due to dead code that hasn't yet been removed. Coverage will be back as soon as I do some more cleaning.
It would be nice to have this applied quickly.