网友收藏【深入kotlin】 - 创建协程_携程runblocking-CSDN博客文章浏览阅读2.4k次。创建协程的方式主要有:launch()、async()、coroutineScope()、runBlocking() 。launch()创建一个异步协程(非阻塞),返回一个不带返回值的 job。fun main(){ GlobalScope.launch{// 默认 CorutineDispatcher 为 Dispatchers.Default delay(1000...... 2024-01-25 11:11 评论 0 阅读 阅读全文