soot.util
Class SourceLocator

java.lang.Object
  |
  +--soot.util.SourceLocator

public class SourceLocator
extends java.lang.Object

Provides utility methods to retrieve an input stream for a class name, given a classfile, or jimple or baf output files.


Field Summary
static int PRECEDENCE_BAF
          Constant indicating that Baf is preferred input stream.
static int PRECEDENCE_CLASS
          Constant indicating that classfiles (via Coffi) are preferred input stream.
static int PRECEDENCE_JIMPLE
          Constant indicating that Jimple is preferred input stream.
static int PRECEDENCE_NONE
          Constant for default source precedence.
 
Method Summary
static java.io.InputStream getInputStreamOf(java.lang.String className)
          Given a class name, uses the default soot-class-path to return an input stream for the given class.
static java.io.InputStream getInputStreamOf(java.lang.String classPath, java.lang.String className)
          Given a class name and class-path, returns an input stream for the given class.
static void setSrcPrecedence(int precedence)
          Sets the source precedence.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PRECEDENCE_NONE

public static final int PRECEDENCE_NONE
Constant for default source precedence.

See Also:
Constant Field Values

PRECEDENCE_CLASS

public static final int PRECEDENCE_CLASS
Constant indicating that classfiles (via Coffi) are preferred input stream.

See Also:
Constant Field Values

PRECEDENCE_JIMPLE

public static final int PRECEDENCE_JIMPLE
Constant indicating that Jimple is preferred input stream.

See Also:
Constant Field Values

PRECEDENCE_BAF

public static final int PRECEDENCE_BAF
Constant indicating that Baf is preferred input stream.

See Also:
Constant Field Values
Method Detail

setSrcPrecedence

public static void setSrcPrecedence(int precedence)
Sets the source precedence.


getInputStreamOf

public static java.io.InputStream getInputStreamOf(java.lang.String className)
                                            throws java.lang.ClassNotFoundException
Given a class name, uses the default soot-class-path to return an input stream for the given class.

java.lang.ClassNotFoundException

getInputStreamOf

public static java.io.InputStream getInputStreamOf(java.lang.String classPath,
                                                   java.lang.String className)
                                            throws java.lang.ClassNotFoundException
Given a class name and class-path, returns an input stream for the given class.

java.lang.ClassNotFoundException