shannah / Java-Objective-C-Bridge

A thin bridge that allows for two-way communication from Java to Objective-C.
123 stars 25 forks source link

Thoughts of merging into JNA #1

Open rednoah opened 10 years ago

rednoah commented 10 years ago

I've only used this project to do same basic calls into Objective C (the Security Scoped Bookmarks NSURL methods) but it's been working extremely well for me, and getting things done went much more smooth than originally expected.

So first of all congrats on an amazingly simple yet powerful library! I get the feeling it's heavily under-appreciated...

Not sure if this ever came up, nor have I asked twall from JNA about this, but wouldn't your Objective-C-Bridge fit right in with the JNA project?

shannah commented 10 years ago

Glad it's working well for you. The security scoped bookmarks was one of the things I originally developed this for in my own projects.

I'm happy to contribute the code into jna, but I suspect that it doesn't really for into that project's goals. Jna seems to be a platform independent library whereas the objc bridge is strictly for os x. That said, if he wants to integrate it, he's welcome to.

teras commented 9 years ago

There is a part of JNA, the jna-platform, which has exactly jna bindings to base/core system libraries. Probably it will fit there?

shannah commented 9 years ago

I have posted an issue in the JNA issue tracker to see if there is any interest.

rednoah commented 9 years ago

Here's my original thread: https://groups.google.com/forum/#!searchin/jna-users/Objective$20C/jna-users/cyCiIT2-6g0/aNj7oMAt5EQJ

I think jna-platform is platform specific bindings, but it's all Java and not extending anything on the JNA native code. So for Java-Objective-C-Bridge we'd need to add the native code to the JNA native component.

LOG-TAG commented 5 years ago

porting JNA to JNI will be a good thing?

rednoah commented 5 years ago

Adding a random note: Java-Objective-C-Bridge and JNA have overlapping packages (presumably so that Java-Objective-C-Bridge can access JNA protected methods) which is something the new Java Module System really really doesn't like.

shannah commented 5 years ago

Good point about the JPMS package overlap issue. I have fixed it so that there is no longer a package overlap.

rednoah commented 3 years ago

https://github.com/java-native-access/jna/issues/370