add func biz
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
package com.mogo.eagle.core.function.call.devatools
|
||||
|
||||
import android.util.Log
|
||||
import androidx.annotation.Nullable
|
||||
import com.mogo.eagle.core.function.api.devatools.IMoGoDevaToolsFuncConfigListener
|
||||
import com.zhjt.service_biz.SubBiz
|
||||
@@ -10,6 +11,8 @@ object CallerDevaToolsFuncConfigListenerManager {
|
||||
private val M_DEVA_TOOLS_FUNC_CONFIG_LISTENER: ConcurrentHashMap<String, IMoGoDevaToolsFuncConfigListener> =
|
||||
ConcurrentHashMap()
|
||||
|
||||
private val cacheMap = mutableMapOf<String,MutableList<SubBiz>>()
|
||||
|
||||
/**
|
||||
* 添加监听
|
||||
* @param tag 标记,用来注销监听使用
|
||||
@@ -24,6 +27,10 @@ object CallerDevaToolsFuncConfigListenerManager {
|
||||
return
|
||||
}
|
||||
M_DEVA_TOOLS_FUNC_CONFIG_LISTENER["$biz'_'$tag"] = listener
|
||||
|
||||
cacheMap[biz]?.let {
|
||||
invokeDevaToolsFuncConfigBizUpdate(biz,it)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -56,6 +63,7 @@ object CallerDevaToolsFuncConfigListenerManager {
|
||||
* 由订阅方判断Type类型,聚合一些
|
||||
*/
|
||||
fun invokeDevaToolsFuncConfigBizUpdate(biz: String, list: MutableList<SubBiz>) {
|
||||
cacheMap[biz] = list
|
||||
M_DEVA_TOOLS_FUNC_CONFIG_LISTENER.forEach {
|
||||
val key = it.key
|
||||
if (key.contains(biz)) {
|
||||
|
||||
Reference in New Issue
Block a user