A solution to track a batch of HTTP requests in swift 3.0

后端 未结 3 556
伪装坚强ぢ
伪装坚强ぢ 2021-01-27 13:10

I am using swift 3.0 running under iOS 10.0 and I want to craft some code that fires when a batch condition is met.

for i in 0 ..< rex {
   async code, disapp         


        
3条回答
  •  Happy的楠姐
    2021-01-27 14:07

    So I'm pretty sure what you want can be found here. Basically you want to use GCD and have a completion closure. It's one line of code, which always makes me giggle. A longer post on the topic is here.

提交回复
热议问题