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
If we want to be able to pass objects between different generated bindings, we should make the generated bindings for the standard library reusable and put them in package:jni.
The java stdlib is quite large. One approach is to only extract the important bits, like ArrayList, and make them common. (We are kind of already doing that with java.lang.String which maps to JniString, it's a small change in generator to do the same with more types).
Another approach is to figure out the general problem of interop between 2 or more jnigen-generated packages.
In simple case, we can just list the special-cased type mappings in YAML.
For larger bindings, maybe generate a JSON file and let typename resolver in generator take care of it?
Activity
mahesh-hegde commentedon Sep 26, 2022
The java stdlib is quite large. One approach is to only extract the important bits, like ArrayList, and make them common. (We are kind of already doing that with java.lang.String which maps to JniString, it's a small change in generator to do the same with more types).
Another approach is to figure out the general problem of interop between 2 or more jnigen-generated packages.
In simple case, we can just list the special-cased type mappings in YAML.
For larger bindings, maybe generate a JSON file and let typename resolver in generator take care of it?
HosseinYousefi commentedon May 22, 2024
Tracked in #746.