polyglot.ast
Interface Term

All Superinterfaces:
java.lang.Cloneable, Copy, JL, Node, NodeOps
All Known Subinterfaces:
AmbAssign, AmbExpr, ArrayAccess, ArrayAccessAssign, ArrayInit, Assert, Assign, Binary, Block, BooleanLit, Branch, Call, Case, Cast, Catch, CharLit, ClassBody, ClassDecl, ClassLit, ClassMember, CodeDecl, CofferClassDecl, CofferConstructorDecl, CofferMethodDecl, CompoundStmt, Conditional, ConstructorCall, ConstructorDecl, Do, Empty, Eval, Expr, Field, FieldAssign, FieldDecl, FloatLit, For, ForInit, Formal, ForUpdate, Free, If, Initializer, Instanceof, IntLit, Labeled, Lit, Local, LocalAssign, LocalClassDecl, LocalDecl, Loop, MethodDecl, New, NewArray, NullLit, NumLit, ProcedureCall, ProcedureDecl, Return, Special, Stmt, StringLit, Switch, SwitchBlock, SwitchElement, Synchronized, Throw, Try, Unary, VarDecl, Variable, While
All Known Implementing Classes:
AbstractBlock_c, AmbAssign_c, AmbExpr_c, ArrayAccess_c, ArrayAccessAssign_c, ArrayInit_c, Assert_c, Assign_c, Binary_c, Block_c, BooleanLit_c, Branch_c, Call_c, Case_c, Cast_c, Catch_c, CharLit_c, ClassBody_c, ClassDecl_c, ClassLit_c, CofferClassDecl_c, CofferConstructorDecl_c, CofferMethodDecl_c, Conditional_c, ConstructorCall_c, ConstructorDecl_c, Do_c, Empty_c, Eval_c, Expr_c, Field_c, FieldAssign_c, FieldDecl_c, FloatLit_c, For_c, Formal_c, Free_c, If_c, Initializer_c, Instanceof_c, IntLit_c, Labeled_c, Lit_c, Local_c, LocalAssign_c, LocalClassDecl_c, LocalDecl_c, Loop_c, MethodDecl_c, New_c, NewArray_c, NullLit_c, NumLit_c, Return_c, Special_c, Stmt_c, StringLit_c, Switch_c, SwitchBlock_c, Synchronized_c, Term_c, Throw_c, Try_c, Unary_c, While_c

public interface Term
extends Node

A Term represents any Java expression or statement on which dataflow can be performed.


Method Summary
 java.util.List acceptCFG(CFGBuilder v, java.util.List succs)
          Visit this node, calling calling v.edge() for each successor in succs, if data flows on that edge.
 Term entry()
          Return the first (sub)term performed when evaluating this term.
 SubtypeSet exceptions()
          List of Types with all exceptions possibly thrown by this term.
 Term exceptions(SubtypeSet exceptions)
           
 boolean reachable()
          Returns true if the term is reachable.
 Term reachable(boolean reachability)
          Set the reachability of this term.
 
Methods inherited from interface polyglot.ast.Node
childExpectedType, del, del, dump, ext, ext, ext, ext, position, position, visit, visitChild, visitEdge, visitList
 
Methods inherited from interface polyglot.ast.JL
init, node
 
Methods inherited from interface polyglot.ast.NodeOps
addDecls, addMembers, addMembersEnter, buildTypes, buildTypesEnter, disambiguate, disambiguateEnter, enterScope, enterScope, exceptionCheck, exceptionCheckEnter, prettyPrint, throwTypes, translate, typeCheck, typeCheckEnter, visitChildren
 
Methods inherited from interface polyglot.util.Copy
copy
 

Method Detail

entry

Term entry()
Return the first (sub)term performed when evaluating this term.


acceptCFG

java.util.List acceptCFG(CFGBuilder v,
                         java.util.List succs)
Visit this node, calling calling v.edge() for each successor in succs, if data flows on that edge.


reachable

boolean reachable()
Returns true if the term is reachable. This attribute is not guaranteed correct until after the reachability pass.

See Also:
ReachChecker

reachable

Term reachable(boolean reachability)
Set the reachability of this term.


exceptions

SubtypeSet exceptions()
List of Types with all exceptions possibly thrown by this term. The list is not necessarily correct until after exception-checking. polyglot.ast.NodeOps.throwTypes() is similar, but exceptions are not propagated to the containing node.


exceptions

Term exceptions(SubtypeSet exceptions)