'Is it possible to run Java16 code on Android
I know Java 16/17/18 is not compatible with java 8 (android), but is-it a way to generate byte-code for android to execute the program on my phone?
Or trans-code the java16 in an other language for android?
Note: I Use too many "records" to rewrite in java-8
Solution 1:[1]
The answer as of now is No.
However, apparently, work is underway to add support for Java 16+ record types to Android; see https://issuetracker.google.com/issues/197081367
Solution 2:[2]
You can't use the Jave 16.
The last version is 11, you check this. https://developer.android.com/studio/releases/gradle-plugin?utm_source=android-studio-2020-3-1&utm_medium=studio-assistant-stable#java-11
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Stephen C |
| Solution 2 | Rasoul Miri |
