Class FindIndentXmlVisitor<P>


  • public class FindIndentXmlVisitor<P>
    extends XmlVisitor<P>
    Discover the most common indentation level of a tree, and whether this indentation is built with spaces or tabs.
    • Constructor Detail

      • FindIndentXmlVisitor

        public FindIndentXmlVisitor​(int enclosingIndent)
    • Method Detail

      • preVisit

        public Xml preVisit​(Xml tree,
                            P p)
        Overrides:
        preVisit in class org.openrewrite.TreeVisitor<Xml,​P>
      • isIndentedWithSpaces

        public boolean isIndentedWithSpaces()
      • getMostCommonIndent

        public int getMostCommonIndent()
      • getTotalLines

        public int getTotalLines()
        Returns:
        The total number of source lines that this indent decision was made on.