Package com.ibm.wala.util.config
Class AnalysisScopeReader
- java.lang.Object
-
- com.ibm.wala.util.config.AnalysisScopeReader
-
- Direct Known Subclasses:
DexAnalysisScopeReader
public class AnalysisScopeReader extends Object
ReadsAnalysisScope
from a text file.
-
-
Field Summary
Fields Modifier and Type Field Description protected static String
BASIC_FILE
-
Constructor Summary
Constructors Constructor Description AnalysisScopeReader()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
addClassPathToScope(String classPath, AnalysisScope scope, ClassLoaderReference loader)
static AnalysisScope
makeJavaBinaryAnalysisScope(String classPath, File exclusionsFile)
static AnalysisScope
makePrimordialScope(File exclusionsFile)
static void
processScopeDefLine(AnalysisScope scope, ClassLoader javaLoader, String line)
static AnalysisScope
read(AnalysisScope scope, String scopeFileName, File exclusionsFile, ClassLoader javaLoader, FileProvider fp)
protected static AnalysisScope
read(AnalysisScope scope, URI scopeFileURI, File exclusionsFile, ClassLoader javaLoader, FileProvider fp)
static AnalysisScope
readJavaScope(String scopeFileName, File exclusionsFile, ClassLoader javaLoader)
read in an analysis scope for a Java application from a text file
-
-
-
Field Detail
-
BASIC_FILE
protected static final String BASIC_FILE
- See Also:
- Constant Field Values
-
-
Method Detail
-
readJavaScope
public static AnalysisScope readJavaScope(String scopeFileName, File exclusionsFile, ClassLoader javaLoader) throws IOException
read in an analysis scope for a Java application from a text file- Parameters:
scopeFileName
- the text file specifying the scopeexclusionsFile
- a file specifying code to be excluded from the scope; can benull
javaLoader
- the class loader used to read in files referenced in the scope file, viaClassLoader.getResource(String)
- Returns:
- the analysis scope
- Throws:
IOException
-
read
public static AnalysisScope read(AnalysisScope scope, String scopeFileName, File exclusionsFile, ClassLoader javaLoader, FileProvider fp) throws IOException
- Throws:
IOException
-
read
protected static AnalysisScope read(AnalysisScope scope, URI scopeFileURI, File exclusionsFile, ClassLoader javaLoader, FileProvider fp) throws IOException
- Throws:
IOException
-
processScopeDefLine
public static void processScopeDefLine(AnalysisScope scope, ClassLoader javaLoader, String line) throws IOException
- Throws:
IOException
-
makePrimordialScope
public static AnalysisScope makePrimordialScope(File exclusionsFile) throws IOException
- Parameters:
exclusionsFile
- file holding class hierarchy exclusions. may be null- Throws:
IOException
IllegalStateException
- if there are problmes reading wala properties
-
makeJavaBinaryAnalysisScope
public static AnalysisScope makeJavaBinaryAnalysisScope(String classPath, File exclusionsFile) throws IOException
- Parameters:
classPath
- class path to analyze, delimited byFile.pathSeparator
exclusionsFile
- file holding class hierarchy exclusions. may be null- Throws:
IOException
IllegalStateException
- if there are problems reading wala properties
-
addClassPathToScope
public static void addClassPathToScope(String classPath, AnalysisScope scope, ClassLoaderReference loader)
-
-