public final class FeatureTreeNode extends Object
| Modifier and Type | Method and Description |
|---|---|
void |
addChild(FeatureTreeNode child)
Add a child to the node
|
static FeatureTreeNode |
createChildMetadataNode(String name,
FeatureTreeNode parent)
Creates new Feature Tree Node
|
static FeatureTreeNode |
createChildNode(String name,
FeatureTreeNode parent)
Creates new Feature Tree Node
|
static FeatureTreeNode |
createRootMetadataNode(String name) |
static FeatureTreeNode |
createRootNode(String name) |
boolean |
equals(Object obj) |
Map<String,String> |
getAttributes() |
List<FeatureTreeNode> |
getChildren() |
String |
getName() |
String |
getValue() |
int |
hashCode() |
boolean |
isMetadataNode() |
void |
setAttribute(String attributeName,
String attributeValue)
Added attribute for the node
|
void |
setValue(String value)
Add value to the node
|
String |
toString()
{ @inheritDoc }
|
public static FeatureTreeNode createRootNode(String name) throws FeatureParsingException
name - the name of the nodeFeatureParsingException - whenpublic static FeatureTreeNode createChildNode(String name, FeatureTreeNode parent) throws FeatureParsingException
name - name of the nodeparent - parent of the nodeFeatureParsingException - occurs when parent of the new node has String valuepublic static FeatureTreeNode createRootMetadataNode(String name) throws FeatureParsingException
name - the name of the nodeFeatureParsingException - whenpublic static FeatureTreeNode createChildMetadataNode(String name, FeatureTreeNode parent) throws FeatureParsingException
name - name of the nodeparent - parent of the nodeFeatureParsingException - occurs when parent of the new node has String valuepublic String getName()
public String getValue()
public List<FeatureTreeNode> getChildren()
public void addChild(FeatureTreeNode child) throws FeatureParsingException
child - new child node for the current nodeFeatureParsingException - occurs when child adds to node with value or if the node is a metadata nodepublic void setValue(String value) throws FeatureParsingException
value - valueFeatureParsingException - occurs when value adds to the node with childrens or if the object is a metadata
node and the value is not a hex stringpublic boolean isMetadataNode()
public Map<String,String> getAttributes()
public void setAttribute(String attributeName, String attributeValue)
attributeName - name of the attributeattributeValue - value of the attributeCopyright © 2015–2016 The veraPDF Consortium. All rights reserved.