public abstract class NodeInstantiator extends java.lang.Object implements Function<DAGNode<Component,Dependency>,java.lang.Object>
Instantiate graph nodes.
Constructor and Description |
---|
NodeInstantiator() |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
apply(DAGNode<Component,Dependency> input) |
static NodeInstantiator |
create()
Create a node instantiator without a lifecycle manager.
|
static NodeInstantiator |
create(LifecycleManager mgr)
Create a node instantiator with a lifecycle manager.
|
abstract java.lang.Object |
instantiate(DAGNode<Component,Dependency> node)
Instantiate a particular node in the graph.
|
public static NodeInstantiator create()
Create a node instantiator without a lifecycle manager.
public static NodeInstantiator create(@WillNotClose LifecycleManager mgr)
Create a node instantiator with a lifecycle manager.
mgr
- The lifecycle manager to use.public abstract java.lang.Object instantiate(DAGNode<Component,Dependency> node) throws InjectionException
Instantiate a particular node in the graph.
node
- The node to instantiate.InjectionException
@Nonnull public java.lang.Object apply(@Nullable DAGNode<Component,Dependency> input)
apply
in interface java.util.function.Function<DAGNode<Component,Dependency>,java.lang.Object>