You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The scanner's ManagedTypeToJniDescriptor() method maps managed types to JNI descriptors for [Export] method signatures. It correctly handles primitives (bool → Z, int → I, etc.) and string → Ljava/lang/String;, but falls back to Ljava/lang/Object; for all other types:
// Scanner/JavaPeerScanner.cs:1096-1097// Fallback: any other type maps to Objectreturn"Ljava/lang/Object;";
This means [Export] methods with parameters like Android.Graphics.Bitmap, Java.Util.ArrayList, or any custom Java-bound type will get incorrect JNI signatures in the generated JCW.
The ManagedTypeToJniDescriptor() method needs to resolve Java-bound types by looking up their [Register] attribute to find the correct JNI type name. The type resolution can use the existing AssemblyIndex infrastructure to look up the target type's [Register] attribute.
Impact
Any [Export] method with non-primitive, non-string parameters will have an incorrect JNI signature. This will cause NoSuchMethodError at runtime when Java tries to call the exported method with the correct parameter types.
Activity