public class ComponentLookupService extends Object
| Constructor and Description |
|---|
ComponentLookupService(EffectiveNode top) |
| Modifier and Type | Method and Description |
|---|---|
<T> LinkedHashMap<String,T> |
getChildren(String parentName,
Class<T> classFilter)
gets the children of a Component in the EffectiveNode and filters by Class.
|
Object |
getComponentByName(String name)
return any object registered by the dictionaries of the service.
|
String |
getFullPathFor(String componentName) |
Map.Entry<String,Object> |
getParent(String componentName)
gets the Parent of a component in the EffectiveNode tree.
|
<T> List<T> |
listChildren(String parentName,
Class<T> klass)
lists the children of a component.
|
void |
proceduralNodeWalk(String startingNodeName,
Consumer<EffectiveNode> pre,
Consumer<EffectiveNode> post)
Tree walking starting from the top node.
|
<T> void |
proceduralWalk(String startingNodeName,
Class<T> klass,
Consumer<T> pre,
Consumer<T> post)
Tree walking starting from the top node.
|
<T> void |
treeWalk(String startingNodeName,
Class<T> klass,
Function<T,TreeWalkerDiag> func,
Consumer<T> post)
Walks the components tree recursively, applying rules of TreeWalkerDiag (the walk
can be interrupted by HANDLING_CHILDREN (the code is not invoked on children)
or STOP (the code abruptly ends).
|
public ComponentLookupService(EffectiveNode top)
public Object getComponentByName(String name)
name - public <T> LinkedHashMap<String,T> getChildren(String parentName, Class<T> classFilter)
T - parentName - classFilter - public <T> List<T> listChildren(String parentName, Class<T> klass)
T - parentName - klass - public Map.Entry<String,Object> getParent(String componentName)
componentName - public <T> void proceduralWalk(String startingNodeName, Class<T> klass, Consumer<T> pre, Consumer<T> post)
T - startingNodeName - the name of the node to start the procedure from.klass - pre - the procedure to apply in pre orderpost - the procedure to apply in post orderpublic void proceduralNodeWalk(String startingNodeName, Consumer<EffectiveNode> pre, Consumer<EffectiveNode> post)
startingNodeName - pre - post - public <T> void treeWalk(String startingNodeName, Class<T> klass, Function<T,TreeWalkerDiag> func, Consumer<T> post)
T - startingNodeName - klass - func - post - Copyright © 2016 LSST. All rights reserved.