Class ExceptionBlockImpl
java.lang.Object
org.checkerframework.dataflow.cfg.block.BlockImpl
org.checkerframework.dataflow.cfg.block.SingleSuccessorBlockImpl
org.checkerframework.dataflow.cfg.block.ExceptionBlockImpl
- All Implemented Interfaces:
Block,ExceptionBlock,SingleSuccessorBlock,org.plumelib.util.UniqueId
Implementation of
ExceptionBlock.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.checkerframework.dataflow.cfg.block.Block
Block.BlockType -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final Map<TypeMirror, Set<Block>> Set of exceptional successors.The node of this block.Fields inherited from class org.checkerframework.dataflow.cfg.block.SingleSuccessorBlockImpl
flowRule, successorFields inherited from class org.checkerframework.dataflow.cfg.block.BlockImpl
predecessors, type -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddExceptionalSuccessor(BlockImpl b, TypeMirror cause) Add an exceptional successor.Returns the list of exceptional successor blocks as an unmodifiable map.Returns the last node of this block, or null if none.getNode()Returns the node of this block.getNodes()Returns the nodes contained within this basic block.Returns the successors of this basic block.voidSet the node.toString()Methods inherited from class org.checkerframework.dataflow.cfg.block.SingleSuccessorBlockImpl
getFlowRule, getSuccessor, setFlowRule, setSuccessorMethods inherited from class org.checkerframework.dataflow.cfg.block.BlockImpl
addPredecessor, getPredecessors, getType, getUid, removePredecessorMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.checkerframework.dataflow.cfg.block.Block
getPredecessors, getTypeMethods inherited from interface org.checkerframework.dataflow.cfg.block.SingleSuccessorBlock
getFlowRule, getSuccessor, setFlowRuleMethods inherited from interface org.plumelib.util.UniqueId
getClassAndUid, getUid
-
Field Details
-
node
The node of this block. -
exceptionalSuccessors
Set of exceptional successors.
-
-
Constructor Details
-
ExceptionBlockImpl
public ExceptionBlockImpl()Create an empty exceptional block.
-
-
Method Details
-
setNode
Set the node. -
getNode
Description copied from interface:ExceptionBlockReturns the node of this block.- Specified by:
getNodein interfaceExceptionBlock- Returns:
- the node of this block
-
getNodes
Returns the nodes contained within this basic block. The list may be empty.The following invariant holds.
forall n in getNodes() :: n.getBlock() == this
This implementation returns a singleton list.
-
getLastNode
Description copied from interface:BlockReturns the last node of this block, or null if none.- Specified by:
getLastNodein interfaceBlock- Returns:
- the last node of this block or
null
-
addExceptionalSuccessor
Add an exceptional successor.- Parameters:
b- the successorcause- the exception type that leads to the given block
-
getExceptionalSuccessors
Description copied from interface:ExceptionBlockReturns the list of exceptional successor blocks as an unmodifiable map.- Specified by:
getExceptionalSuccessorsin interfaceExceptionBlock- Returns:
- the list of exceptional successor blocks as an unmodifiable map
-
getSuccessors
Description copied from interface:BlockReturns the successors of this basic block.- Specified by:
getSuccessorsin interfaceBlock- Overrides:
getSuccessorsin classSingleSuccessorBlockImpl- Returns:
- the successors of this basic block
-
toString
-