Class CFGProcessor
java.lang.Object
javax.annotation.processing.AbstractProcessor
org.checkerframework.javacutil.AbstractTypeProcessor
org.checkerframework.javacutil.BasicTypeProcessor
org.checkerframework.dataflow.cfg.CFGProcessor
- All Implemented Interfaces:
Processor
Generates the control flow graph of a given method in a given class. See
CFGVisualizeLauncher for example usage.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classThe result of the CFG process; contains the control flow graph when successful. -
Field Summary
Fields inherited from class org.checkerframework.javacutil.BasicTypeProcessor
currentRootFields inherited from class javax.annotation.processing.AbstractProcessor
processingEnv -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected TreePathScanner<?, ?> Creates a TreePathScanner at the given root.Returns the CFG process result.voidA method to be called once all the classes are processed.Methods inherited from class org.checkerframework.javacutil.BasicTypeProcessor
typeProcessMethods inherited from class org.checkerframework.javacutil.AbstractTypeProcessor
getCompilerLog, init, process, typeProcessingStartMethods inherited from class javax.annotation.processing.AbstractProcessor
getCompletions, getSupportedAnnotationTypes, getSupportedOptions, isInitialized
-
Constructor Details
-
CFGProcessor
Creates a CFG processor.- Parameters:
className- the qualified name of the class that defines the methodmethodName- the name of the method to generate the CFG for
-
-
Method Details
-
getCFGProcessResult
Returns the CFG process result.- Returns:
- result of cfg process
-
typeProcessingOver
public void typeProcessingOver()Description copied from class:AbstractTypeProcessorA method to be called once all the classes are processed.Subclasses can override this method to do any aggregate analysis (e.g., generate a report, persistence) or resource deallocation.
Method
AbstractTypeProcessor.getCompilerLog()can be used to access the number of compiler errors.- Overrides:
typeProcessingOverin classAbstractTypeProcessor
-
createTreePathScanner
Description copied from class:BasicTypeProcessorCreates a TreePathScanner at the given root.- Specified by:
createTreePathScannerin classBasicTypeProcessor- Parameters:
root- where to start the tree traversal- Returns:
- a TreePathScanner at the given root
-
getSupportedSourceVersion
- Specified by:
getSupportedSourceVersionin interfaceProcessor- Overrides:
getSupportedSourceVersionin classAbstractProcessor
-