Class TraversalUtilVisitor<T>

java.lang.Object
org.docx4j.utils.TraversalUtilVisitor<T>
Direct Known Subclasses:
Docx4J.FindContentControlsVisitor, FieldsCombiner.CombineVisitor, PageNumberInformationCollector.FieldVisitor, VariablePrepare.TraversalUtilParagraphVisitor

public abstract class TraversalUtilVisitor<T>
extends java.lang.Object
Extend this class to specify what should be done when a particular object (eg P or Table) is visited during the traversal.
Author:
alberto
  • Constructor Summary

    Constructors 
    Constructor Description
    TraversalUtilVisitor()  
  • Method Summary

    Modifier and Type Method Description
    void apply​(T element)
    Apply method if there is no need to access the surrounding elements
    void apply​(T element, java.lang.Object parent, java.util.List<java.lang.Object> siblings)  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • apply

      public void apply​(T element, java.lang.Object parent, java.util.List<java.lang.Object> siblings)
      Parameters:
      element -
      parent - (logical?)parent in the of the element
      siblings - List of the element (this includes the element itself). This list can't be changed while the visitor is running(!)
    • apply

      public void apply​(T element)
      Apply method if there is no need to access the surrounding elements
      Parameters:
      element -