4 ms·
I was thinking more along the lines of libraries supporting protocols, formats, cryptosystems, and the like -- stuff that doesn't require interacting with the A
by simmons 12y ago
I was thinking more along the lines of libraries supporting protocols, formats, cryptosystems, and the like -- stuff that doesn't require interacting with the Android API.
Being able to use the Android API from Rust (or any other non-Java language) is an interesting problem, though. Unfortunately, as you mention, the API is strongly tied to specific Java/Dalvik classes and methods (the stuff in framework.jar). Many of these merely proxy to backend services over Binder/AIDL, but the Binder/AIDL calls and associated data structures are subject to change. Sometimes I wish there was a standardized interface for native code to communicate directly with backend services over Binder, but that would likely create more headaches than it would fix.
- on_and_off 12y agoI am not sure their are a lot of use-cases for this where there is not already a great java or c++ library. So I fear that it might not make a lot of sense to use Rust for most apps. Regarding the API, IMO a solution can only come from Google. There are good arguments in favor of replacing Java by Rust (or a Rust inspired language managed by Google) and even to rewrite the app framework foundations in order to improve the current offering. Officially, Java is the language of the platform, but that does not necessarily mean that they won't replace it in time.