40 #if defined(ENABLE_JNI_HEADERS)
41 # include "native/vm/include/java_lang_VMRuntime.h"
203 if (libname == NULL) {
211 return library.
load(env);
225 if (libname == NULL) {
static int processors_online()
Returns the number of online processors in the system.
Table containing all native methods registered with the VM.
NativeMethods & get_nativemethods()
void register_methods(Utf8String classname, const JNINativeMethod *methods, size_t count)
Register native methods with the VM.
JNIEXPORT jstring JNICALL Java_java_lang_VMRuntime_mapLibraryName(JNIEnv *env, jclass clazz, jstring libname)
JNIEXPORT jint JNICALL Java_java_lang_VMRuntime_availableProcessors(JNIEnv *env, jclass clazz)
Utf8String to_utf8() const
void _Jv_java_lang_VMRuntime_init(void)
#define NATIVE_METHODS_COUNT
static JavaString from_utf8(Utf8String)
const char * c_str()
get contents of buffer as zero-terminated c-style-string This strings lifetime is tied to it's buffer...
JNIEXPORT void JNICALL Java_java_lang_VMRuntime_runFinalizersOnExit(JNIEnv *env, jclass clazz, jboolean value)
JNIEnv jclass jobject const char * name
JNIEXPORT void JNICALL Java_java_lang_VMRuntime_traceInstructions(JNIEnv *env, jclass clazz, jboolean par1)
void vm_shutdown()
Hook point before the VM is actually destroyed.
s8 gc_get_free_bytes(void)
#define NATIVE_LIBRARY_PREFIX
s8 gc_get_max_heap_size(void)
classloader_t * loader_hashtable_classloader_add(java_handle_t *cl)
JNIEXPORT void JNICALL Java_java_lang_VMRuntime_gc(JNIEnv *env, jclass clazz)
void gc_invoke_finalizers(void)
bool load(JNIEnv *env)
Load this native library and initialize it, if possible.
void gc_finalize_all(void)
JNIEXPORT jint JNICALL Java_java_lang_VMRuntime_nativeLoad(JNIEnv *env, jclass clazz, jstring libname, jobject loader)
void exceptions_throw_nullpointerexception(void)
JNIEXPORT jlong JNICALL Java_java_lang_VMRuntime_maxMemory(JNIEnv *env, jclass clazz)
static bool finalizeOnExit
static Utf8String from_utf8(const char *, size_t)
JNIEnv jclass jobject loader
Represents a native library.
static JNINativeMethod methods[]
JNIEXPORT jlong JNICALL Java_java_lang_VMRuntime_totalMemory(JNIEnv *env, jclass clazz)
#define NATIVE_LIBRARY_SUFFIX
s8 gc_get_heap_size(void)
JNIEXPORT void JNICALL Java_java_lang_VMRuntime_runFinalization(JNIEnv *env, jclass clazz)
JNIEXPORT void JNICALL Java_java_lang_VMRuntime_runFinalizationForExit(JNIEnv *env, jclass clazz)
JNIEXPORT void JNICALL Java_java_lang_VMRuntime_exit(JNIEnv *env, jclass clazz, jint status)
JNIEXPORT jlong JNICALL Java_java_lang_VMRuntime_freeMemory(JNIEnv *env, jclass clazz)
JNIEXPORT void JNICALL Java_java_lang_VMRuntime_traceMethodCalls(JNIEnv *env, jclass clazz, jboolean par1)
static VM * get_current()