Details
-
Type: Wish
-
Status: Closed
-
Priority: Major
-
Resolution: Duplicate
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: PicoContainer (Java)
-
Labels:None
-
Number of attachments :
Description
Typically in my usage of PicoContainer I end up with an adapter chain that is fairly deep.
JMX -> Caching -> MyCustomComponentAdapters -> CICA
I find that I'm wanting two methods:
1 - ComponentAdapter.swapInstantiatingAdapter(InstantiatingComponentAdapter newMethod);
This would save me from having to recreate the entire ComponentAdapterChain for the few times I actually need setter injection. And since in my environment, clients can plug-in their own components, clients wouldn't even be ABLE to accurately recreate the component adapter chain.
The result would be something like this:
ComponentAdapter ca = pico.registerComponentImplementation(NeedsSetterInjection.class);
ComponentAdapter setterAdapter = new ComponentAdapter(.... all the appopriate args);
ca.swapInstantiatingAdapter(setterAdapter);
2 - ComponentAdapter.getAdapterOfType(Class adapterType) throws AdapterNotInChainException
Because in:
JMX -> Caching -> MyCustomComponentAdapters -> CICA
There is no "real" way of getting to MyCustomComponentAdapters for any final modifications and tweaking.
Obviously both of these items would break the current Interface so I'm at a loss on how to get what I want out of it. So I decided to file it as a wish unless someone comes up with an idea on how to integrate it.
Activity
Field | Original Value | New Value |
---|---|---|
Status | Open [ 1 ] | Closed [ 6 ] |
Resolution | Duplicate [ 3 ] |
The whole adapter chaining in the current state is awful. See
PICO-220for a better approach.