标签: android kotlin observable
我想将FlowableList转换为List。有什么建议吗?
private val flowableList: Flowable<List<T>> private val list = listOf<T>(flowableList)
答案 0 :(得分:2)
只需使用toList方法
toList
val list = flowableList.toList().map { it.flatten() }