Hi there, I’m facing a interesting IllegalAccessEr...
# android
z
Hi there, I’m facing a interesting IllegalAccessError when I integrate Zoom Java SDK into my App with Kotlin 1.3.11 The SDK interface is something like this:
Copy code
package us.zoom.sdk;

class StartMeetingParams { }
public class StartMeetingParamsWithoutLogin extends StartMeetingParams { }
public interface MeetingService {
    int startMeetingWithParams(Context var1, StartMeetingParams var2);
}
Note that StartMeetingParams is package-private. My Kotlin code is like this:
Copy code
val params = StartMeetingParamsWithoutLogin().apply { some code }
meetingService.startMeetingWithParams(context, params)
It crashed and thrown a IllegalAccessError with message like “tried to access class StartMeetingParams”. Then I re-written my code with Java and it works good. I guess the reason is public class CAN NOT inherit internal class in Kotlin. But I still want to implement it with Kotlin. Is there anyway to do it? Am I missing something?