Package org.verapdf.features.tools
Class FeatureTreeNode
java.lang.Object
org.verapdf.features.tools.FeatureTreeNode
Feature Tree Node for Feature Reporter
- Author:
- Maksim Bezrukov
-
Method Summary
Modifier and TypeMethodDescriptionAdd a child to the nodeaddChild(FeatureTreeNode node) addMetadataChild(String nodeName) Add a child to the nodestatic final FeatureTreeNodecreateRootNode(String name) booleangetName()getValue()inthashCode()booleanvoidsetAttribute(String attributeName, String attributeValue) Added attribute for the nodevoidsetAttributes(Map<String, String> toSet) voidAdd value to the nodetoString(){ @inheritDoc }
-
Method Details
-
getName
- Returns:
- name of the node
-
getValue
- Returns:
- value of the node
-
getChildren
- Returns:
- list of all children nodes for this node
-
addChild
Add a child to the node- Parameters:
nodeName- new child node for the current node- Throws:
FeatureParsingException- occurs when child adds to node with value or if the node is a metadata node
-
addMetadataChild
Add a child to the node- Parameters:
nodeName- new child node for the current node- Throws:
FeatureParsingException- occurs when child adds to node with value or if the node is a metadata node
-
addChild
- Throws:
FeatureParsingException
-
setValue
Add value to the node- Parameters:
value- value- Throws:
FeatureParsingException- occurs when value adds to the node with children or if the object is a metadata node and the value is not a hex string
-
isMetadataNode
public boolean isMetadataNode() -
getAttributes
- Returns:
- Map object with keys equals to attributes names and values for them equals to attributes values
-
setAttribute
Added attribute for the node- Parameters:
attributeName- name of the attributeattributeValue- value of the attribute
-
setAttributes
-
createRootNode
-
hashCode
public int hashCode() -
equals
-
toString
{ @inheritDoc }
-