Binding Jar file failes because java.lang.object is not mapped to correct namespace

crecre USUniversity ✭✭

I get the following error when trying to bind a jar file:
The type or namespace name 'Lang' does not exist in the namespace 'Org.Hsqldb.Lib.Java' (are you missing an assembly reference?)

When looking into the generated code, the error seems to be the mapping of java.lang.object:

[Register ("heap")] protected IList<Java.Lang.Object> Heap { get { if (heap_jfieldId == IntPtr.Zero) heap_jfieldId = JNIEnv.GetFieldID (class_ref, "heap", "[Ljava/lang/Object;"); return JavaArray<global::Java.Lang.Object>.FromJniHandle (JNIEnv.GetObjectField (Handle, heap_jfieldId), JniHandleOwnership.TransferLocalRef); } set { if (heap_jfieldId == IntPtr.Zero) heap_jfieldId = JNIEnv.GetFieldID (class_ref, "heap", "[Ljava/lang/Object;"); IntPtr native_value = JavaArray<global::Java.Lang.Object>.ToLocalJniHandle (value); JNIEnv.SetField (Handle, heap_jfieldId, native_value); JNIEnv.DeleteLocalRef (native_value); } }

The generic type is Java.Lang.Object instead of global::Java.Lang.Object. All other uses of java.lang.object are mapped correctly.
Can I fix this with the Metadata.xml or is this an error in the binding process?

Sign In or Register to comment.