public final class CFGVisualizeLauncher extends Object
Usage: Directly run it as the main class to generate the DOT representation of the control
flow graph of a given method in a given class. See ConstantPropagationPlayground for another way to
use it.
| Modifier and Type | Method and Description |
|---|---|
static <V extends AbstractValue<V>,S extends Store<S>,T extends TransferFunction<V,S>> |
generateDOTofCFG(String inputFile,
String outputDir,
String method,
String clas,
boolean pdf,
boolean verbose,
@Nullable Analysis<V,S,T> analysis)
Generate the DOT representation of the CFG for a method.
|
static <V extends AbstractValue<V>,S extends Store<S>,T extends TransferFunction<V,S>> |
generateStringOfCFG(String inputFile,
String method,
String clas,
boolean verbose,
@Nullable Analysis<V,S,T> analysis)
Generate the String representation of the CFG for a method.
|
static void |
main(String[] args)
The main entry point of CFGVisualizeLauncher.
|
static void |
writeStringOfCFG(String inputFile,
String method,
String clas,
String outputFile,
Analysis<?,?,?> analysis)
Write generated String representation of the CFG for a method to a file.
|
public static void main(String[] args)
args - the passed arguments, see printUsage() for the usagepublic static <V extends AbstractValue<V>,S extends Store<S>,T extends TransferFunction<V,S>> void generateDOTofCFG(String inputFile, String outputDir, String method, String clas, boolean pdf, boolean verbose, @Nullable Analysis<V,S,T> analysis)
V - the abstract value type to be tracked by the analysisS - the store type used in the analysisT - the transfer function type that is used to approximated runtime behaviorinputFile - a Java source file, used as inputoutputDir - source output directorymethod - name of the method to generate the CFG forclas - name of the class which includes the method to generate the CFG forpdf - also generate a PDFverbose - show verbose information in CFGanalysis - analysis to perform before the visualization (or null if no analysis
is to be performed)public static void writeStringOfCFG(String inputFile, String method, String clas, String outputFile, Analysis<?,?,?> analysis)
inputFile - a Java source file, used as inputmethod - name of the method to generate the CFG forclas - name of the class which includes the method to generate the CFG foroutputFile - source output fileanalysis - instance of forward or backward analysis from specific dataflow test casepublic static <V extends AbstractValue<V>,S extends Store<S>,T extends TransferFunction<V,S>> @Nullable Map<String,Object> generateStringOfCFG(String inputFile, String method, String clas, boolean verbose, @Nullable Analysis<V,S,T> analysis)
V - the abstract value type to be tracked by the analysisS - the store type used in the analysisT - the transfer function type that is used to approximated runtime behaviorinputFile - a Java source file, used as inputmethod - name of the method to generate the CFG forclas - name of the class which includes the method to generate the CFG forverbose - show verbose information in CFGanalysis - analysis to perform before the visualization (or null if no analysis
is to be performed)