public static class XMLTreeReplacer.Node extends Object
hasChange() is true.
The Node has at least one change if:
hasChange() method return truegetOccurrence() value is greater or equal than 0, and the index of the node in its parent is equal to getOccurrence()getOccurrence() value is -1, getIfQName() is not null and the value of the corresponding attribute in the same Node
has the getIfValue() value| Constructor and Description |
|---|
Node(QName qname)
Constructor.
|
Node(QName qname,
int occ)
Constructor.
|
Node(QName qname,
String ifQName,
String ifValue)
Constructor.
|
Node(String qname)
Constructor.
|
Node(String qname,
int occ)
Constructor.
|
Node(String qname,
String ifQName,
String ifValue)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
Map<String,String> |
getAttributes()
Return the attributes changes.
|
String |
getIfQName()
Return the attribute qualified name to check for the change.
|
String |
getIfValue()
Return the attribute value to use check the change.
|
String |
getName()
Return the Node name.
|
int |
getOccurrence()
Return the Node occurrence.
|
QName |
getQName()
Return the Node qualified name.
|
boolean |
hasChange()
Return true if the Node has a change.
|
void |
setAttribute(String name,
String value)
Set an attribute change
|
public Node(QName qname)
qname - the Node namepublic Node(String qname)
qname - the Node namepublic Node(QName qname, String ifQName, String ifValue)
qname - the Node nameifQName - the attribute qualified name to check for the changeifValue - the attribute value to use check the changepublic Node(String qname, String ifQName, String ifValue)
qname - the Node nameifQName - the attribute qualified name to check for the changeifValue - the attribute value to use check the changepublic Node(QName qname, int occ)
qname - the Node nameocc - the occurrence of the Nodepublic Node(String qname, int occ)
qname - the Node nameocc - the occurrence of the Nodepublic void setAttribute(String name, String value)
name - the attribute namevalue - the attribute valuepublic Map<String,String> getAttributes()
public int getOccurrence()
public boolean hasChange()
public String getIfQName()
public String getIfValue()
public QName getQName()
public String getName()