Class XpathNodeTracker.TrackingEntry

  • Enclosing class:
    XpathNodeTracker

    private final class XpathNodeTracker.TrackingEntry
    extends java.lang.Object
    Holds node tracking details - one instance is used for each level of indentation in a DOM Provides reference between a String-ified Node value and the xpath index of that value
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private TrackingEntry()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      (package private) void clearTrackedAttribute()
      Clear any reference to the current visited attribute
      private void reset()  
      private void trackAttribute​(javax.xml.namespace.QName visited)
      Keep a reference to the visited attribute at the current visited node
      private void trackNode​(org.w3c.dom.Node visited, java.lang.String value)
      Keep a reference to the current visited (non-attribute) node
      (package private) void trackNodesAsWellAsValues​(boolean yesNo)
      whether the indices of subsequently tracked nodes should be tracked.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • atAttribute

        private boolean atAttribute
      • atChild

        private boolean atChild
      • nextIndex

        private int nextIndex
      • nodeReferenceMap

        private java.util.Map<org.w3c.dom.Node,​java.lang.Integer> nodeReferenceMap
      • trackNodeReferences

        private boolean trackNodeReferences
    • Constructor Detail

      • TrackingEntry

        private TrackingEntry()
    • Method Detail

      • trackNode

        private void trackNode​(org.w3c.dom.Node visited,
                               java.lang.String value)
        Keep a reference to the current visited (non-attribute) node
        Parameters:
        visited - the non-attribute node visited
        value - the String-ified value of the non-attribute node visited
      • trackAttribute

        private void trackAttribute​(javax.xml.namespace.QName visited)
        Keep a reference to the visited attribute at the current visited node
        Parameters:
        visited - the attribute visited
      • clearTrackedAttribute

        void clearTrackedAttribute()
        Clear any reference to the current visited attribute
      • reset

        private void reset()
      • trackNodesAsWellAsValues

        void trackNodesAsWellAsValues​(boolean yesNo)
        whether the indices of subsequently tracked nodes should be tracked.