Unknown opened 4 years ago
|
|
Method position(I)Ljava/nio/ByteBuffer; in class Ljava/nio/ByteBuffer; comes from java.nio.Buffer and it is there (in the Java VM (JDK,JRE) for a very long time. Most likely the issue is caused by Java 9 (or newer) used for building your application for Android (import restrictions created by Java modules) or by Android not providing method which should be there (as it is in the JVM). What is the target version of your project? Java 9 or newer? Do you use Java modules? (or Java modules enabled project) Which version of Android SDK are you targeting? |
|
@hantu85 thank you for your reply. We are using java 1.8.0_242 (built in with android studio) as a targetCompatibility and sourceCompatibility in android gradle. As well as java enabled modules are there using same 1.8 java version. targetSdkVersion 29 for android. |
|
I recompiled everything with Java8 (1.8.0_265) and I added cast to Buffer in problematic place. I also reproduced your error during compilation: when I compiled code using Java 11 and then I switched sdk to 1.8.0 and tried compiling again without cleaning the project. |
|
wojciech.kapcia@tigase.net added "Related" #9 5 months ago
|