public class ModuleScene extends Scene
Scene.AndroidVersionInfoaccessibilityOracle, activeCallGraph, activeFastHierarchy, activeHierarchy, activePointsToAnalysis, activeSideEffectAnalysis, allowsPhantomRefs, applicationClasses, basicclasses, classes, classNumberer, contextNumberer, cscg, doneResolving, dynamicClasses, entryPoints, excludedPackages, fieldNumberer, incrementalBuild, kindNumberer, libraryClasses, localNumberer, mainClass, methodNumberer, phantomClasses, reachableMethods, reservedNames, sootClassPath, subSigNumberer, typeNumberer, unitNumberer| Constructor and Description |
|---|
ModuleScene(Singletons.Global g) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addClassSilent(SootClass c)
Adds the given class to the Scene.
|
void |
addRefType(RefType type) |
boolean |
containsClass(String className) |
boolean |
containsClass(String className,
com.google.common.base.Optional<String> moduleName) |
boolean |
containsType(String className) |
void |
extendSootClassPath(String newPathElement) |
void |
extendSootModulePath(String newPathElement) |
SootClass |
forceResolve(String className,
int level)
Forces Soot to resolve the class with the given name to the given level, even if resolving has actually already
finished.
|
SootClass |
forceResolve(String className,
int level,
com.google.common.base.Optional<String> moduleName) |
SootMethod |
getMainMethod() |
RefType |
getObjectType()
|
RefType |
getOrAddRefType(RefType tp) |
RefType |
getOrAddRefType(String className,
com.google.common.base.Optional<String> moduleName) |
RefType |
getRefType(String className)
Returns the RefType with the given className.
|
RefType |
getRefType(String className,
com.google.common.base.Optional<String> moduleName)
Returns the RefType with the given className.
|
RefType |
getRefTypeUnsafe(String className)
Returns the RefType with the given className.
|
RefType |
getRefTypeUnsafe(String className,
com.google.common.base.Optional<String> moduleName)
Returns the RefType with the given className.
|
SootClass |
getSootClass(String className)
Returns the SootClass with the given className.
|
SootClass |
getSootClass(String className,
com.google.common.base.Optional<String> moduleName) |
String |
getSootClassPath() |
SootClass |
getSootClassUnsafe(String className)
Returns the SootClass with the given className.
|
SootClass |
getSootClassUnsafe(String className,
com.google.common.base.Optional<String> moduleName) |
String |
getSootModulePath() |
Type |
getType(String arg,
com.google.common.base.Optional<String> moduleName)
Returns the RefType with the given class name or primitive type.
|
void |
loadBasicClasses()
Load just the set of basic classes soot needs, ignoring those specified on the command-line.
|
SootClass |
loadClass(String className,
int desiredLevel) |
SootClass |
loadClass(String className,
int desiredLevel,
com.google.common.base.Optional<String> moduleName) |
SootClass |
loadClassAndSupport(String className)
Loads the given class and all of the required support classes.
|
SootClass |
loadClassAndSupport(String className,
com.google.common.base.Optional<String> moduleName) |
void |
loadDynamicClasses() |
void |
loadNecessaryClasses()
Load the set of classes that soot needs, including those specified on the command-line.
|
SootClass |
makeSootClass(String className) |
SootClass |
makeSootClass(String name,
String moduleName) |
protected void |
prepareClasses()
Generate classes to process, adding or removing package marked by command line options.
|
void |
setMainClassFromOptions() |
void |
setSootClassPath(String p) |
void |
setSootModulePath(String p) |
SootClass |
tryLoadClass(String className,
int desiredLevel,
com.google.common.base.Optional<String> moduleName)
Attempts to load the given class and all of the required support classes.
|
static ModuleScene |
v() |
addBasicClass, addBasicClass, addClass, addReflectionTraceClasses, allowsPhantomRefs, containsField, containsMethod, createLocalCreation, createLocalCreation, createLocalGenerator, defaultClassPath, defaultJavaClassPath, doneResolving, dynamicClasses, getActiveHierarchy, getAndroidAPIVersion, getAndroidJarPath, getAndroidSDKVersionInfo, getApplicationClasses, getBasicClasses, getCallGraph, getClasses, getClasses, getClassNumberer, getClientAccessibilityOracle, getContextNumberer, getContextSensitiveCallGraph, getDefaultThrowAnalysis, getEntryPoints, getFastHierarchy, getField, getFieldNumberer, getLibraryClasses, getLocalNumberer, getMainClass, getMethod, getMethodNumberer, getOrAddRefType, getOrMakeFastHierarchy, getPhantomClasses, getPhantomRefs, getPkgList, getPointsToAnalysis, getReachableMethods, getReservedNames, getSideEffectAnalysis, getSootClassUnsafe, getState, getSubSigNumberer, getType, getTypeNumberer, getTypeUnsafe, getTypeUnsafe, getUnitNumberer, grabField, grabMethod, hasActiveHierarchy, hasCallGraph, hasClientAccessibilityOracle, hasCustomEntryPoints, hasFastHierarchy, hasMainClass, hasPointsToAnalysis, hasReachableMethods, hasSideEffectAnalysis, incrementalBuildFinished, initiateIncrementalBuild, internalMakeCallGraph, isApk, isBasicClass, isExcluded, isExcluded, isIncluded, isIncluded, isIncrementalBuild, isJavaGEQ9, kindNumberer, loadNecessaryClass, makeConstructorRef, makeFieldRef, makeMethodRef, makeSootClass, makeSootField, makeSootField, makeSootMethod, makeSootMethod, makeSootMethod, modifyHierarchy, quotedNameOf, releaseActiveHierarchy, releaseCallGraph, releaseClientAccessibilityOracle, releaseFastHierarchy, releasePointsToAnalysis, releaseReachableMethods, releaseSideEffectAnalysis, removeClass, setActiveHierarchy, setCallGraph, setClientAccessibilityOracle, setContextNumberer, setContextSensitiveCallGraph, setDefaultThrowAnalysis, setDoneResolving, setEntryPoints, setFastHierarchy, setMainClass, setPhantomRefs, setPkgList, setPointsToAnalysis, setReachableMethods, setSideEffectAnalysis, signatureToClass, signatureToSubsignature, tryLoadClass, unescapeNamepublic ModuleScene(Singletons.Global g)
public static ModuleScene v()
public SootMethod getMainMethod()
getMainMethod in class Scenepublic void extendSootClassPath(String newPathElement)
extendSootClassPath in class Scenepublic void extendSootModulePath(String newPathElement)
public String getSootClassPath()
getSootClassPath in class Scenepublic void setSootClassPath(String p)
setSootClassPath in class Scenepublic String getSootModulePath()
public void setSootModulePath(String p)
protected void addClassSilent(SootClass c)
SceneaddClassSilent in class Scenec - The class to addpublic boolean containsClass(String className)
containsClass in class Scenepublic boolean containsClass(String className, com.google.common.base.Optional<String> moduleName)
public boolean containsType(String className)
containsType in class Scenepublic SootClass tryLoadClass(String className, int desiredLevel, com.google.common.base.Optional<String> moduleName)
public SootClass loadClassAndSupport(String className)
loadClassAndSupport in class Scenepublic SootClass loadClassAndSupport(String className, com.google.common.base.Optional<String> moduleName)
public SootClass loadClass(String className, int desiredLevel, com.google.common.base.Optional<String> moduleName)
public Type getType(String arg, com.google.common.base.Optional<String> moduleName)
RuntimeException - if the Type for this name cannot be found. Use getRefTypeUnsafe(String, Optional) to check if type is
an registered RefType.public RefType getRefType(String className, com.google.common.base.Optional<String> moduleName)
IllegalStateException - if the RefType for this class cannot be found. Use containsType(String) to check if type is
registeredpublic RefType getRefType(String className)
ScenegetRefType in class Scenepublic RefType getObjectType()
ScenegetObjectType in class Scenepublic RefType getRefTypeUnsafe(String className, com.google.common.base.Optional<String> moduleName)
public RefType getRefTypeUnsafe(String className)
ScenegetRefTypeUnsafe in class Scenepublic void addRefType(RefType type)
public SootClass getSootClassUnsafe(String className)
ScenegetSootClassUnsafe in class SceneclassName - The name of the class to getpublic SootClass getSootClassUnsafe(String className, com.google.common.base.Optional<String> moduleName)
public SootClass getSootClass(String className)
ScenegetSootClass in class SceneclassName - The name of the class to get; throws RuntimeException if this class does not exist.public SootClass getSootClass(String className, com.google.common.base.Optional<String> moduleName)
public void loadBasicClasses()
SceneScene.loadNecessaryClasses(), though it will only waste time.loadBasicClasses in class Scenepublic void loadNecessaryClasses()
loadNecessaryClasses in class Scenepublic void loadDynamicClasses()
loadDynamicClasses in class Sceneprotected void prepareClasses()
prepareClasses in class Scenepublic void setMainClassFromOptions()
setMainClassFromOptions in class Scenepublic SootClass forceResolve(String className, int level)
SceneforceResolve in class Scenepublic SootClass forceResolve(String className, int level, com.google.common.base.Optional<String> moduleName)
public SootClass makeSootClass(String className)
makeSootClass in class SceneCopyright © 2021 Soot OSS. All rights reserved.