安装
可以通过获得 。 要安装它,只需将以下行添加到您的Podfile中:
pod 'Deferred' , :git => 'https://github.com/vandilsonlima/Deferred.git' , :branch => 'master'
我们可以这样使用它:
async {
let value = task (). await (). value
let value2 = task2 (value). await (). value
let value3 = task3 (value2). await (). value
print (value3)
}
代替这个:
task { value in
task2 (value) { value2 in
task3 (value2) { value3 in
评论0
最新资源