etebase-java icon indicating copy to clipboard operation
etebase-java copied to clipboard

Introduce a Kotlin Multiplatform Mobile library

Open mainrs opened this issue 3 years ago • 1 comments

KMM is a way to write code that runs on Android, iOS, native and the JVM. Common code is written in Kotlin and platform-specific code can then be used to implement lowlevel details (in this case networking).

The current etebase-java java implementation only works on Android. Rewriting it could make it possible to run it on Android and the JVM. Taking it a step further one could also include iOS support.

I am not familar with how native DLL loading would work in this case. I took a glimse at the code in this repository but do not really understand how it works to be honest. Does the Rust code generate all the necessary classes on built (deterministically)?

mainrs avatar May 16 '22 15:05 mainrs

The Rust code generates a binary and Java code that wraps around and loads this binary.

The reason why it's Android only at the moment is because I wasn't able to find a reliable way to distribute and load binaries on non-Android.

tasn avatar May 16 '22 15:05 tasn