-
-
Save JohnProg/a85f70fbe8d3f5a50d01 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Uncomment both lines below if testing on an Xcode playground. | |
//import XCPlayground | |
//XCPSetExecutionShouldContinueIndefinitely() | |
let url = NSURL(string: "http://www.stackoverflow.com") | |
let task = NSURLSession.sharedSession().dataTaskWithURL(url) {(data, response, error) in | |
println(NSString(data: data, encoding: NSUTF8StringEncoding)) | |
} | |
task.resume() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment