public final class StaticFactoryAdapter<T> extends AbstractAdapter<T>
StaticFactory.ComponentAdapter.NOTHING| Constructor and Description |
|---|
StaticFactoryAdapter(Class<T> type,
StaticFactory<T> staticFactory)
Construct a ComponentAdapter accessing a static factory creating the component.
|
StaticFactoryAdapter(Object componentKey,
Class<T> type,
StaticFactory<T> staticFactory)
Construct a ComponentAdapter accessing a static factory creating the component using a special key for addComponent
registration.
|
| Modifier and Type | Method and Description |
|---|---|
T |
getComponentInstance(PicoContainer container,
Type into) |
String |
getDescriptor() |
void |
verify(PicoContainer container) |
accept, changeMonitor, checkTypeCompatibility, currentMonitor, findAdapterOfType, getComponentImplementation, getComponentInstance, getComponentKey, getDelegate, toStringpublic StaticFactoryAdapter(Class<T> type, StaticFactory<T> staticFactory)
type - The type of the created component.staticFactory - Wrapper instance for the static factory.public StaticFactoryAdapter(Object componentKey, Class<T> type, StaticFactory<T> staticFactory)
componentKey - The key of the created component.type - The type of the created component.staticFactory - Wrapper instance for the static factory.public T getComponentInstance(PicoContainer container, Type into) throws PicoCompositionException
PicoCompositionExceptionorg.picocontainer.ComponentAdapter#getComponentInstance(org.picocontainer.PicoContainer, java.lang.Class into)public void verify(PicoContainer container) throws PicoVerificationException
public String getDescriptor()
Copyright © 2003-2014 Codehaus. All Rights Reserved.