Using NSURLSession from a Swift command line program

后端 未结 3 1115
星月不相逢
星月不相逢 2020-12-08 01:17

I\'m trying to test a little proof-of-concept command line app prior to integrating it into a larger app. What I\'m trying to do is download some data using NSURLSession usi

3条回答
  •  不知归路
    2020-12-08 01:19

    For proof of concept(s) or tryouts/testing purposes, you can simplify asynchronous complexity by hard coding some timeout period until your stuff finishes. (see notes below)

    SWIFT 5

        //...your magic here
        // add a little 

提交回复
热议问题