[desc]:修复蓝牙模块依赖问题

[author]:wangyimiao
master
yimiao 3 years ago
parent 8ef7ebdebf
commit c09e677048

@ -62,10 +62,9 @@ project.ext {
annotationProcessor : "com.github.bumptech.glide:compiler:${versions.glide}", annotationProcessor : "com.github.bumptech.glide:compiler:${versions.glide}",
photo_view : "com.github.chrisbanes:PhotoView:${versions.photo_view}", photo_view : "com.github.chrisbanes:PhotoView:${versions.photo_view}",
luban : "top.zibin:Luban:${versions.luban}", luban : "top.zibin:Luban:${versions.luban}",
gson : "com.google.code.gson:gson${versions.gson}", gson : "com.google.code.gson:gson:${versions.gson}",
arouter : "com.alibaba:arouter-api:${versions.arouter}", arouter : "com.alibaba:arouter-api:${versions.arouter}",
arouter_compiler : "com.alibaba:arouter-compiler:${versions.arouter}", arouter_compiler : "com.alibaba:arouter-compiler:${versions.arouter}",
] ]
/** /**

@ -23,4 +23,6 @@ dependencies {
implementation rootProject.ext.dependencies.kotlin implementation rootProject.ext.dependencies.kotlin
// rxAndroid // rxAndroid
implementation rootProject.ext.dependencies.rxandroid implementation rootProject.ext.dependencies.rxandroid
// gson
implementation rootProject.ext.dependencies.gson
} }

@ -24,9 +24,9 @@ import java.util.HashSet;
import java.util.Set; import java.util.Set;
import java.util.UUID; import java.util.UUID;
import io.reactivex.Observable; import io.reactivex.rxjava3.core.Observable;
import io.reactivex.ObservableEmitter; import io.reactivex.rxjava3.core.ObservableEmitter;
import io.reactivex.ObservableOnSubscribe; import io.reactivex.rxjava3.core.ObservableOnSubscribe;
/** /**
* *

@ -3,8 +3,8 @@ package com.common.bluetooth.interfaces
import android.bluetooth.BluetoothDevice import android.bluetooth.BluetoothDevice
import com.common.bluetooth.BtConstants.BLUETOOTH_TYPE import com.common.bluetooth.BtConstants.BLUETOOTH_TYPE
import com.common.bluetooth.callback.BaseResultCallback import com.common.bluetooth.callback.BaseResultCallback
import io.reactivex.Observable import io.reactivex.rxjava3.core.Observable
import java.util.* import java.util.UUID
/** /**
* 蓝牙客户端接口 * 蓝牙客户端接口

@ -25,9 +25,10 @@ import java.util.concurrent.LinkedBlockingQueue;
import java.util.concurrent.atomic.AtomicBoolean; import java.util.concurrent.atomic.AtomicBoolean;
import java.util.concurrent.atomic.AtomicInteger; import java.util.concurrent.atomic.AtomicInteger;
import io.reactivex.Observable; import io.reactivex.rxjava3.core.Observable;
import io.reactivex.Observer; import io.reactivex.rxjava3.core.Observer;
import io.reactivex.disposables.Disposable; import io.reactivex.rxjava3.disposables.Disposable;
/** /**
* BLE * BLE

@ -21,7 +21,8 @@ import java.util.concurrent.atomic.AtomicBoolean;
import java.util.concurrent.atomic.AtomicInteger; import java.util.concurrent.atomic.AtomicInteger;
import java.util.concurrent.atomic.AtomicLong; import java.util.concurrent.atomic.AtomicLong;
import io.reactivex.functions.Consumer; import io.reactivex.rxjava3.functions.Consumer;
/** /**
* Service for managing connection and data communication with a GATT server * Service for managing connection and data communication with a GATT server
@ -416,7 +417,7 @@ public class BluetoothLeConnector {
try { try {
action.accept(gattCharacteristic); action.accept(gattCharacteristic);
} catch (Exception e) { } catch (Throwable e) {
e.printStackTrace(); e.printStackTrace();
} }
} }

@ -15,3 +15,4 @@ org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
# Android operating system, and which are packaged with your app"s APK # Android operating system, and which are packaged with your app"s APK
# https://developer.android.com/topic/libraries/support-library/androidx-rn # https://developer.android.com/topic/libraries/support-library/androidx-rn
android.useAndroidX=true android.useAndroidX=true
android.enableJetifier=true
Loading…
Cancel
Save