FileDocCategorySizeDatePackage
NativeStart.javaAPI DocAndroid 1.5 API1469Wed May 06 22:41:02 BST 2009dalvik.system

NativeStart

public class NativeStart extends Object implements Runnable
Dummy class used during JNI initialization. The JNI functions want to be able to create objects, and the VM needs to discard the references when the function returns. That gets a little weird when we're calling JNI functions from the C main(), and there's no Java stack frame to hitch the references onto. Rather than having some special-case code, we create this simple little class and pretend that it called the C main(). This also comes in handy when a native thread attaches itself with the JNI AttachCurrentThread call. If they attach the thread and start creating objects, we need a fake frame to store stuff in.

Fields Summary
Constructors Summary
private NativeStart()

Methods Summary
private static native voidmain(java.lang.String[] dummy)

public native voidrun()