|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface TreeBuilder
Method Summary | |
---|---|
ProcessingNode |
build(Configuration tree)
Build a processing tree from a Configuration . |
ProcessingNode |
build(Source source)
|
ProcessingNodeBuilder |
createNodeBuilder(Configuration config)
|
Object |
getAttribute(String name)
Get the value of an attribute. |
List |
getDisposableNodes()
Return the list of ProcessingNodes part of this tree that are
Disposable . |
String |
getFileName()
|
String |
getLanguage()
Returns the language that is being built (e.g. |
String |
getNamespace()
Get the namespace URI that builders should use to find their nodes. |
String |
getParameterName()
Returns the name of the parameter element. |
ConcreteTreeProcessor |
getProcessor()
|
ProcessingNode |
getRegisteredNode(String name)
|
ComponentManager |
getSitemapComponentManager()
Return the sitemap component manager |
String |
getTypeForStatement(Configuration statement,
String role)
Get the type for a statement : it returns the 'type' attribute if present, and otherwhise the default hint for the ComponentSelector identified by
the role role . |
boolean |
registerNode(String name,
ProcessingNode node)
Register a ProcessingNode under a given name. |
void |
setAttribute(String name,
Object value)
Add an attribute. |
void |
setProcessor(ConcreteTreeProcessor processor)
|
ProcessingNode |
setupNode(ProcessingNode node,
Configuration config)
Setup a ProcessingNode by setting its location, calling all
the lifecycle interfaces it implements and giving it the parameter map if
it's a ParameterizableNode . |
Method Detail |
---|
void setProcessor(ConcreteTreeProcessor processor)
ConcreteTreeProcessor getProcessor()
String getLanguage()
String getParameterName()
boolean registerNode(String name, ProcessingNode node)
ProcessingNode
under a given name.
For example, ResourceNodeBuilder
stores here the ProcessingNode
s
it produces for use by sitemap pipelines. This allows to turn the tree into a graph.
If a node with the name is already registed, the process fails!
true
is returned; otherwise false.ProcessingNode getRegisteredNode(String name)
IllegalStateException
ProcessingNodeBuilder createNodeBuilder(Configuration config) throws Exception
Exception
String getNamespace()
ProcessingNode build(Configuration tree) throws Exception
Configuration
.
Exception
ProcessingNode build(Source source) throws Exception
Exception
String getFileName()
List getDisposableNodes()
ProcessingNodes
part of this tree that are
Disposable
. Care should be taken to properly dispose them before
trashing the processing tree.
ProcessingNode setupNode(ProcessingNode node, Configuration config) throws Exception
ProcessingNode
by setting its location, calling all
the lifecycle interfaces it implements and giving it the parameter map if
it's a ParameterizableNode
.
As a convenience, the node is returned by this method to allow constructs
like return treeBuilder.setupNode(new MyNode(), config)
.
Exception
String getTypeForStatement(Configuration statement, String role) throws ConfigurationException
ComponentSelector
identified by
the role role
.
ConfigurationException
- if the default type could not be found.ComponentManager getSitemapComponentManager()
void setAttribute(String name, Object value)
Object getAttribute(String name)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |