adroitandroid / Near

A P2P library for Android for discovery on local networks using UDP and transfer in general using TCP sockets
https://goo.gl/kioAiQ
MIT License
349 stars 92 forks source link

java.lang.NoClassDefFoundError #19

Open jobayerjim9 opened 3 years ago

jobayerjim9 commented 3 years ago

java.lang.NoClassDefFoundError: Failed resolution of: Lkotlin/text/Regex; what is the cause for this error?

Code is below mNearDiscovery = new NearDiscovery.Builder() .setContext(this) .setDiscoverableTimeoutMillis(60000) .setDiscoveryTimeoutMillis(60000) .setDiscoverablePingIntervalMillis(1000) .setDiscoveryListener(getNearDiscoveryListener(), Looper.getMainLooper())

            .build();
    mNearDiscovery.makeDiscoverable("Abcd","");
Fgdou commented 1 year ago

Add this dependency to you gradle file :

implementation 'io.reactivex.rxjava2:rxjava:2.1.8'

This worked for me