FireBaseManager 初步
This commit is contained in:
parent
acac3099a6
commit
a722d84f06
|
|
@ -0,0 +1,46 @@
|
||||||
|
package com.gamedog.statisticreporter.firbase
|
||||||
|
|
||||||
|
import com.ama.core.architecture.BaseApp
|
||||||
|
import kotlinx.coroutines.CoroutineScope
|
||||||
|
import kotlinx.coroutines.Dispatchers
|
||||||
|
import kotlinx.coroutines.SupervisorJob
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
class FireBaseManager private constructor() {
|
||||||
|
companion object {
|
||||||
|
@Volatile
|
||||||
|
private var INSTANCE: FireBaseManager? = null
|
||||||
|
|
||||||
|
fun instance(): FireBaseManager {
|
||||||
|
return INSTANCE ?: synchronized(this) {
|
||||||
|
INSTANCE ?: FireBaseManager().also { INSTANCE = it }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private val mAppContext = BaseApp.appContext()
|
||||||
|
private val mBgScope = CoroutineScope(SupervisorJob() + Dispatchers.Default)
|
||||||
|
private val mMainScope = CoroutineScope(SupervisorJob() + Dispatchers.Main)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
fun init(fireAppId: String) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//----------------------- PRIVATE ------------------------//
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -5,7 +5,6 @@ import cn.thinkingdata.analytics.TDAnalytics
|
||||||
import cn.thinkingdata.analytics.TDAnalytics.TDAutoTrackEventType
|
import cn.thinkingdata.analytics.TDAnalytics.TDAutoTrackEventType
|
||||||
import cn.thinkingdata.analytics.TDConfig
|
import cn.thinkingdata.analytics.TDConfig
|
||||||
import cn.thinkingdata.analytics.ThinkingAnalyticsSDK
|
import cn.thinkingdata.analytics.ThinkingAnalyticsSDK
|
||||||
import cn.thinkingdata.analytics.ThinkingAnalyticsSDK.AutoTrackEventType
|
|
||||||
import com.ama.core.architecture.BaseApp
|
import com.ama.core.architecture.BaseApp
|
||||||
import kotlinx.coroutines.CoroutineScope
|
import kotlinx.coroutines.CoroutineScope
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
|
|
@ -13,7 +12,7 @@ import kotlinx.coroutines.SupervisorJob
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
import org.json.JSONException
|
import org.json.JSONException
|
||||||
import org.json.JSONObject
|
import org.json.JSONObject
|
||||||
import java.util.Dictionary
|
|
||||||
|
|
||||||
|
|
||||||
class ShushuManager private constructor() {
|
class ShushuManager private constructor() {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue