soot.jimple.toolkits.pointer.nativemethods
Class JavaLangClassLoaderNative

java.lang.Object
  extended by soot.jimple.toolkits.pointer.nativemethods.NativeMethodClass
      extended by soot.jimple.toolkits.pointer.nativemethods.JavaLangClassLoaderNative

public class JavaLangClassLoaderNative
extends NativeMethodClass


Field Summary
 
Fields inherited from class soot.jimple.toolkits.pointer.nativemethods.NativeMethodClass
helper
 
Constructor Summary
JavaLangClassLoaderNative(NativeHelper helper)
           
 
Method Summary
 void java_lang_ClassLoader_defineClass0(SootMethod method, ReferenceVariable thisVar, ReferenceVariable returnVar, ReferenceVariable[] params)
          Converts an array of bytes into an instance of class Class.
 void java_lang_ClassLoader_findBootstrapClass(SootMethod method, ReferenceVariable thisVar, ReferenceVariable returnVar, ReferenceVariable[] params)
          NOTE: undocumented, finding the bootstrap class Assuming all classes private native java.lang.Class findBootstrapClass(java.lang.String) throws java.lang.ClassNotFoundException;
 void java_lang_ClassLoader_findLoadedClass(SootMethod method, ReferenceVariable thisVar, ReferenceVariable returnVar, ReferenceVariable[] params)
          Finds the class with the given name if it had been previously loaded through this class loader.
 void java_lang_ClassLoader_getCallerClassLoader(SootMethod method, ReferenceVariable thisVar, ReferenceVariable returnVar, ReferenceVariable[] params)
          Returns a variable pointing to the only class loader static native java.lang.ClassLoader getCallerClassLoader();
 void simulateMethod(SootMethod method, ReferenceVariable thisVar, ReferenceVariable returnVar, ReferenceVariable[] params)
          Implements the abstract method simulateMethod.
 
Methods inherited from class soot.jimple.toolkits.pointer.nativemethods.NativeMethodClass
defaultMethod
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JavaLangClassLoaderNative

public JavaLangClassLoaderNative(NativeHelper helper)
Method Detail

simulateMethod

public void simulateMethod(SootMethod method,
                           ReferenceVariable thisVar,
                           ReferenceVariable returnVar,
                           ReferenceVariable[] params)
Implements the abstract method simulateMethod. It distributes the request to the corresponding methods by signatures.

Specified by:
simulateMethod in class NativeMethodClass

java_lang_ClassLoader_defineClass0

public void java_lang_ClassLoader_defineClass0(SootMethod method,
                                               ReferenceVariable thisVar,
                                               ReferenceVariable returnVar,
                                               ReferenceVariable[] params)
Converts an array of bytes into an instance of class Class. Before the Class can be used it must be resolved. NOTE: an object representing an class object. To be conservative, the side-effect of this method will return an abstract reference points to all possible class object in current analysis environment. private native java.lang.Class defineClass0(java.lang.String, byte[], int, int, java.security.ProtectionDomain);


java_lang_ClassLoader_findBootstrapClass

public void java_lang_ClassLoader_findBootstrapClass(SootMethod method,
                                                     ReferenceVariable thisVar,
                                                     ReferenceVariable returnVar,
                                                     ReferenceVariable[] params)
NOTE: undocumented, finding the bootstrap class Assuming all classes private native java.lang.Class findBootstrapClass(java.lang.String) throws java.lang.ClassNotFoundException;


java_lang_ClassLoader_findLoadedClass

public void java_lang_ClassLoader_findLoadedClass(SootMethod method,
                                                  ReferenceVariable thisVar,
                                                  ReferenceVariable returnVar,
                                                  ReferenceVariable[] params)
Finds the class with the given name if it had been previously loaded through this class loader. NOTE: assuming all classes. protected final native java.lang.Class findLoadedClass(java.lang.String);


java_lang_ClassLoader_getCallerClassLoader

public void java_lang_ClassLoader_getCallerClassLoader(SootMethod method,
                                                       ReferenceVariable thisVar,
                                                       ReferenceVariable returnVar,
                                                       ReferenceVariable[] params)
Returns a variable pointing to the only class loader static native java.lang.ClassLoader getCallerClassLoader();