public class CallGraphGenerator
extends java.lang.Object
main(java.lang.String[])
for the syntax.Constructor and Description |
---|
CallGraphGenerator() |
Modifier and Type | Method and Description |
---|---|
static void |
generateGraphs(java.lang.String[] rootNodes,
int debug)
Implements the core of the call graph generation logic, a call graph
will be generated for each of the root nodes passed.
|
static void |
main(java.lang.String[] args)
Provides a command line interface for an end user to drive the pattern
engine for the purpose of building one or more call graphs.
|
private static void |
syntax(java.lang.String msg,
int rc)
Emit a syntax statement and optional error message to
stderr , then exit the process with the specified return
code. |
static void |
updateGraphs(java.lang.String[] rootNodes,
int debug)
Update the ambiguous external programs and the explicit list of external programs provided
as argument, by re-checking if the ambiguous call-sites can be disambiguated from the hints.
|
private static void |
walkTargets(java.util.Iterator<org.apache.tinkerpop.gremlin.structure.Vertex> walker,
java.lang.String profile)
Walk the targets specified by the given iterator, in batches, until the iterator no longer
provides any new targets.
|
public static void updateGraphs(java.lang.String[] rootNodes, int debug) throws ConfigurationException, AstException, java.io.IOException
rootNodes
- List of Progress AST filenames to use as root nodes or
null
to use the projects defined root node list
(see RootNodeList
).debug
- Debug level.ConfigurationException
AstException
java.io.IOException
public static void generateGraphs(java.lang.String[] rootNodes, int debug) throws ConfigurationException, AstException, java.io.IOException
filename.p.ast
, the resulting call graph will be
named filename.p.ast.graph
.rootNodes
- List of Progress AST filenames to use as root nodes or
null
to use the projects defined root node list
(see RootNodeList
).debug
- Debug level.ConfigurationException
AstException
java.io.IOException
private static void walkTargets(java.util.Iterator<org.apache.tinkerpop.gremlin.structure.Vertex> walker, java.lang.String profile) throws AstException, ConfigurationException
walker
- The target provider.profile
- The profile to be applied against the targets.AstException
ConfigurationException
private static void syntax(java.lang.String msg, int rc)
stderr
, then exit the process with the specified return
code. This method is called from main(java.lang.String[])
when the user passes
command line parameters which are not viable.msg
- Optional error message; may be null
.rc
- Process return code used with System.exit()
.public static void main(java.lang.String[] args)
Syntax:
java CallGraphGenerator [-Dn] [-u] [root_nodes...]Where:
n
is
the numeric setting of the level (default is 1):
Debug level is set to status (1) by default.
If no root nodes are listed on the command line, then the project's
root node list will be used (RootNodeList
).
args
- List of command line arguments.