|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.cmu.cs.crystal.flow.MotherFlowAnalysis<LE>
LE
- the type that represents the analysis knowledgepublic abstract class MotherFlowAnalysis<LE>
Abstract base class for flow analyses that implements a worklist algorithm and provides various methods to access analysis results. Methods are analyzed lazily when results for AST nodes inside a method are requested.
Field Summary | |
---|---|
static Logger |
log
|
Constructor Summary | |
---|---|
MotherFlowAnalysis()
Initializes a fresh flow analysis object. |
Method Summary | |
---|---|
LE |
getEndResults(MethodDeclaration decl)
Gets the lattice results at the end of a method. |
IResult<LE> |
getLabeledEndResult(MethodDeclaration d)
Gets the lattice results at the end of a method. |
IResult<LE> |
getLabeledResultsAfter(ASTNode node)
Retrieves the analysis state that exists after analyzing the node in the control flow graph. |
IResult<LE> |
getLabeledResultsBefore(ASTNode node)
Retrieves the analysis state that exists before analyzing the node in the control flow graph. |
IResult<LE> |
getLabeledStartResult(MethodDeclaration d)
Gets the lattice results at the start of a method. |
LE |
getResultsAfter(ASTNode node)
Deprecated. |
LE |
getResultsAfterAST(ASTNode node)
Retrieves the analysis state that exists after analyzing the node in the abstract syntax tree. |
LE |
getResultsAfterCFG(ASTNode node)
Retrieves the analysis state that exists after analyzing the node in the control flow graph. |
LE |
getResultsBefore(ASTNode node)
Deprecated. |
LE |
getResultsBeforeAST(ASTNode node)
Retrieves the analysis state that exists before analyzing the node in the abstract syntax tree. |
LE |
getResultsBeforeCFG(ASTNode node)
Retrieves the analysis state that exists before analyzing the node in the control flow graph. |
LE |
getStartResults(MethodDeclaration decl)
Gets the lattice results at the start of a method. |
void |
setMonitor(Option<org.eclipse.core.runtime.IProgressMonitor> monitor)
Use the given progress monitor to cancel subsequent flow analysis runs. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final Logger log
Constructor Detail |
---|
public MotherFlowAnalysis()
Method Detail |
---|
public void setMonitor(Option<org.eclipse.core.runtime.IProgressMonitor> monitor)
CancellationException
which,
if not caught, will abort the current overall Crystal analysis job.
monitor
- Monitor to listen for cancellation or Option.none()
if worklist runs should not be canceled.@Deprecated public LE getResultsBefore(ASTNode node)
IFlowAnalysis
getResultsBefore
in interface IFlowAnalysis<LE>
node
- the ASTNode
of interest
IFlowAnalysis.getResultsBeforeCFG(ASTNode)
public LE getResultsBeforeCFG(ASTNode node)
IFlowAnalysis
getResultsBeforeCFG
in interface IFlowAnalysis<LE>
node
- the ASTNode
of interest
IFlowAnalysis.getResultsBeforeAST(ASTNode)
,
IFlowAnalysis.getLabeledResultsBefore(ASTNode)
public LE getResultsBeforeAST(ASTNode node)
IFlowAnalysis
getResultsBeforeAST
in interface IFlowAnalysis<LE>
node
- the ASTNode
of interest
IFlowAnalysis.getResultsBeforeCFG(ASTNode)
@Deprecated public LE getResultsAfter(ASTNode node)
IFlowAnalysis
getResultsAfter
in interface IFlowAnalysis<LE>
node
- the ASTNode
of interest
public LE getResultsAfterCFG(ASTNode node)
IFlowAnalysis
IFlowAnalysis.getResultsAfterAST(ASTNode)
If there are multiple before lattices for this node, they are joined and returned.
getResultsAfterCFG
in interface IFlowAnalysis<LE>
node
- the ASTNode
of interest
IFlowAnalysis.getResultsAfterAST(ASTNode)
,
IFlowAnalysis.getLabeledResultsAfter(ASTNode)
public LE getResultsAfterAST(ASTNode node)
IFlowAnalysis
IFlowAnalysis.getResultsAfterCFG(ASTNode)
If there are multiple before lattices for this node, they are joined and returned.
getResultsAfterAST
in interface IFlowAnalysis<LE>
node
- the ASTNode
of interest
IFlowAnalysis.getResultsAfterCFG(ASTNode)
public LE getEndResults(MethodDeclaration decl)
IFlowAnalysis
getEndResults
in interface IFlowAnalysis<LE>
decl
- The method declaration to get results for
public LE getStartResults(MethodDeclaration decl)
IFlowAnalysis
IFlowAnalysisDefinition.createEntryValue(MethodDeclaration)
getStartResults
in interface IFlowAnalysis<LE>
decl
- The method declaration to get results for
IFlowAnalysisDefinition.createEntryValue(MethodDeclaration)
public IResult<LE> getLabeledResultsBefore(ASTNode node)
IFlowAnalysis
IFlowAnalysis.getResultsBeforeCFG(ASTNode)
, except it keeps all the labels
separated in an IResult
getLabeledResultsBefore
in interface IFlowAnalysis<LE>
node
- the ASTNode
of interest
IFlowAnalysis.getResultsBeforeCFG(ASTNode)
public IResult<LE> getLabeledResultsAfter(ASTNode node)
IFlowAnalysis
IFlowAnalysis.getResultsAfterCFG(ASTNode)
, except it keeps all the labels
separated in an IResult
getLabeledResultsAfter
in interface IFlowAnalysis<LE>
node
- the ASTNode
of interest
IFlowAnalysis.getResultsAfterCFG(ASTNode)
public IResult<LE> getLabeledEndResult(MethodDeclaration d)
IFlowAnalysis
getLabeledEndResult
in interface IFlowAnalysis<LE>
IFlowAnalysis.getEndResults(MethodDeclaration)
public IResult<LE> getLabeledStartResult(MethodDeclaration d)
IFlowAnalysis
IFlowAnalysis.getStartResults(MethodDeclaration)
and
IFlowAnalysisDefinition.createEntryValue(MethodDeclaration)
. However, it might be different
for a system which keeps multiple possible contexts in which the method could be called from based
on some specifications.
getLabeledStartResult
in interface IFlowAnalysis<LE>
IFlowAnalysisDefinition.createEntryValue(MethodDeclaration)
,
IFlowAnalysis.getStartResults(MethodDeclaration)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |