Class TreeUtilsAfterJava11.DeconstructionPatternUtils

  • Enclosing class:
    TreeUtilsAfterJava11

    public static class TreeUtilsAfterJava11.DeconstructionPatternUtils
    extends java.lang.Object
    Utility methods for accessing DeconstructionPatternTree methods.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static com.sun.source.tree.ExpressionTree getDeconstructor​(com.sun.source.tree.Tree tree)
      Returns the deconstruction type of tree.
      static java.util.List<? extends com.sun.source.tree.Tree> getNestedPatterns​(com.sun.source.tree.Tree tree)
      Wrapper around DeconstructionPatternTree#getNestedPatterns.
      • Methods inherited from class java.lang.Object

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

      • getDeconstructor

        public static com.sun.source.tree.ExpressionTree getDeconstructor​(com.sun.source.tree.Tree tree)
        Returns the deconstruction type of tree. Wrapper around DeconstructionPatternTree#getDeconstructor.
        Parameters:
        tree - the DeconstructionPatternTree
        Returns:
        the deconstructor of DeconstructionPatternTree
      • getNestedPatterns

        public static java.util.List<? extends com.sun.source.tree.Tree> getNestedPatterns​(com.sun.source.tree.Tree tree)
        Wrapper around DeconstructionPatternTree#getNestedPatterns.
        Parameters:
        tree - the DeconstructionPatternTree
        Returns:
        the nested patterns of DeconstructionPatternTree