Package sootup.spark
Class SparkCallGraphConfig
java.lang.Object
sootup.spark.SparkCallGraphConfig
- All Implemented Interfaces:
CallGraphConfig
Spark-specific stage of the unified
CallGraphConfig builder chain. Obtained via
CallGraphConfigBuilder.into(SparkCallGraphConfig::from), since sootup.callgraph cannot
depend on sootup.spark directly:
CallGraph cg = CallGraphConfig.builder()
.view(view).entryPoints(entryPoints)
.into(SparkCallGraphConfig::from)
.sparkOptions(SparkOptions.builder().onFlyCallGraph(true).build())
.build()
.computeCallGraph();
In on-the-fly mode (SparkOptions#isOnFlyCallGraph()), the common
CallResolver/VirtualCallResolver/seedEntryPointClinits settings are not
consulted - OTF mode grows its own call graph incrementally and, as of today, has no
<clinit> modeling at all (see Spark's javadoc). Otherwise, they drive a CHA graph built
up front and handed to Spark via callGraph(...), exactly the pattern
sootup.spark.test.options.ClinitHandlingViaCustomCallGraphTest demonstrates by hand.
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescription@NonNull CallGraphBuilds the call graph for the analysis described by this configuration object.static @NonNull SparkCallGraphConfig.Builderfrom(@NonNull CommonCallGraphSettings common) Entry point forCallGraphConfigBuilder.into(SparkCallGraphConfig::from).
-
Method Details
-
from
Entry point forCallGraphConfigBuilder.into(SparkCallGraphConfig::from). -
computeCallGraph
Description copied from interface:CallGraphConfigBuilds the call graph for the analysis described by this configuration object. All state needed (view, entry points, algorithm-specific options) is already captured by the concrete implementation, typically via its own builder.- Specified by:
computeCallGraphin interfaceCallGraphConfig
-