Class Goto

  extended by edu.uci.eecs.doc.cascade.controlflow.Node
      extended by edu.uci.eecs.doc.cascade.controlflow.Goto
All Implemented Interfaces:

public class Goto
extends Node

Represents goto instructions in a control flow tree. It is a "pseudo-node" because unlike other nodes, it does not represent an element of the source code. It is provided for clients of Cascade that require knowledge of goto instructions for timing analysis and other purposes.

Trevor Harmon

Field Summary
Fields inherited from class edu.uci.eecs.doc.cascade.controlflow.Node
block, nextNode, parent, scope, tree
Constructor Summary
Goto(Tree tree, int scope, Node parent, InstructionHandle gotoInstruction)
          Creates a new Goto object.
Method Summary
 List<InstructionHandle> getInstructions()
          Returns a one-element list containing the goto instruction represented by this node.
 String toString()
          Converts the goto node to a string.
Methods inherited from class edu.uci.eecs.doc.cascade.controlflow.Node
getBlock, getEnclosingLoop, getFirstInstruction, getLastInstruction, getMethodInvocations, getMethodInvocations, getNext, getOutermostLoop, getParent, getScope, getSourceCodeLineNumber, getStartAddress, getTree, iterator, lastNode, setNext
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

Constructor Detail


public Goto(Tree tree,
            int scope,
            Node parent,
            InstructionHandle gotoInstruction)
Creates a new Goto object.

tree - the control flow tree to which this node belongs
scope - the lexical scope of the node (0 = top-level scope)
parent - the node's parent (null if the node has no parent)
gotoInstruction - a BCEL object representing the goto instruction
Method Detail


public List<InstructionHandle> getInstructions()
Returns a one-element list containing the goto instruction represented by this node.

getInstructions in class Node
a list of bytecode instructions


public String toString()
Converts the goto node to a string.

toString in class Object
the string "goto"