core :: CString :: to_java_string
This instance is only valid until the next execution of Java code.
You can use new_local_ref
to keep it longer.
# Get a Java string from this C string
#
# This instance is only valid until the next execution of Java code.
# You can use `new_local_ref` to keep it longer.
fun to_java_string: JavaString import sys, Sys.jni_env `{
Sys sys = JavaString_sys(self);
JNIEnv *env = Sys_jni_env(sys);
return (*env)->NewStringUTF(env, self);
`}
lib/java/ffi_support.nit:123,2--131,3