类 TraceDebugEventListener

    • 构造器详细资料

      • TraceDebugEventListener

        public TraceDebugEventListener​(TreeAdaptor adaptor)
    • 方法详细资料

      • enterRule

        public void enterRule​(java.lang.String ruleName)
      • exitRule

        public void exitRule​(java.lang.String ruleName)
      • location

        public void location​(int line,
                             int pos)
        从接口复制的说明: DebugEventListener
        To watch a parser move through the grammar, the parser needs to inform the debugger what line/charPos it is passing in the grammar. For now, this does not know how to switch from one grammar to the other and back for island grammars etc... This should also allow breakpoints because the debugger can stop the parser whenever it hits this line/pos.
        指定者:
        location 在接口中 DebugEventListener
        覆盖:
        location 在类中 BlankDebugEventListener
      • consumeNode

        public void consumeNode​(java.lang.Object t)
        从接口复制的说明: DebugEventListener
        Input for a tree parser is an AST, but we know nothing for sure about a node except its type and text (obtained from the adaptor). This is the analog of the consumeToken method. Again, the ID is the hashCode usually of the node so it only works if hashCode is not implemented. If the type is UP or DOWN, then the ID is not really meaningful as it's fixed--there is just one UP node and one DOWN navigation node.
        指定者:
        consumeNode 在接口中 DebugEventListener
        覆盖:
        consumeNode 在类中 BlankDebugEventListener
      • LT

        public void LT​(int i,
                       java.lang.Object t)
        从接口复制的说明: DebugEventListener
        The tree parser lookedahead. If the type is UP or DOWN, then the ID is not really meaningful as it's fixed--there is just one UP node and one DOWN navigation node.
        指定者:
        LT 在接口中 DebugEventListener
        覆盖:
        LT 在类中 BlankDebugEventListener
      • nilNode

        public void nilNode​(java.lang.Object t)
        从接口复制的说明: DebugEventListener
        A nil was created (even nil nodes have a unique ID... they are not "null" per se). As of 4/28/2006, this seems to be uniquely triggered when starting a new subtree such as when entering a subrule in automatic mode and when building a tree in rewrite mode. If you are receiving this event over a socket via RemoteDebugEventSocketListener then only t.ID is set.
        指定者:
        nilNode 在接口中 DebugEventListener
        覆盖:
        nilNode 在类中 BlankDebugEventListener
      • createNode

        public void createNode​(java.lang.Object t)
        从接口复制的说明: DebugEventListener
        Announce a new node built from token elements such as type etc... If you are receiving this event over a socket via RemoteDebugEventSocketListener then only t.ID, type, text are set.
        指定者:
        createNode 在接口中 DebugEventListener
        覆盖:
        createNode 在类中 BlankDebugEventListener
      • becomeRoot

        public void becomeRoot​(java.lang.Object newRoot,
                               java.lang.Object oldRoot)
        从接口复制的说明: DebugEventListener
        Make a node the new root of an existing root. See Note: the newRootID parameter is possibly different than the TreeAdaptor.becomeRoot() newRoot parameter. In our case, it will always be the result of calling TreeAdaptor.becomeRoot() and not root_n or whatever. The listener should assume that this event occurs only when the current subrule (or rule) subtree is being reset to newRootID. If you are receiving this event over a socket via RemoteDebugEventSocketListener then only IDs are set.
        指定者:
        becomeRoot 在接口中 DebugEventListener
        覆盖:
        becomeRoot 在类中 BlankDebugEventListener
        另请参阅:
        TreeAdaptor.becomeRoot(java.lang.Object, java.lang.Object)