Class PhantomNodeLogic


  • class PhantomNodeLogic
    extends java.lang.Object
    We want to recognize and ignore "phantom" nodes, like the fake type of variable in FieldDeclaration
    • Field Detail

      • isPhantomNodeCache

        private static final java.util.Map<Node,​java.lang.Boolean> isPhantomNodeCache
      • cacheCleaner

        private static final AstObserver cacheCleaner
    • Constructor Detail

      • PhantomNodeLogic

        PhantomNodeLogic()
    • Method Detail

      • isPhantomNode

        static boolean isPhantomNode​(Node node)
      • inPhantomNode

        private static boolean inPhantomNode​(Node node,
                                             int levels)
        A node contained in a phantom node is also a phantom node. We limit how many levels up we check just for performance reasons.