Protocol

URLSessionStreamDelegate

The NSURLSessionStreamDelegate protocol defines delegate methods that you should implement when using URLSession stream tasks. In addition to these methods, be sure to implement the methods in the URLSessionTaskDelegate and URLSessionDelegate protocols to handle events common to all task types and session-level events, respectively.

Overview

Symbols

Delegate Methods

func urlSession(URLSession, readClosedFor: URLSessionStreamTask)

Tells the delegate that the read side of the underlying socket has been closed.

func urlSession(URLSession, writeClosedFor: URLSessionStreamTask)

Tells the delegate that the write side of the underlying socket has been closed.

func urlSession(URLSession, betterRouteDiscoveredFor: URLSessionStreamTask)

Tells the delegate that a better route to the host has been detected for the stream.

func urlSession(URLSession, streamTask: URLSessionStreamTask, didBecome: InputStream, outputStream: OutputStream)

Tells the delegate that the stream task has been completed as a result of the stream task calling the captureStreams() method.

Relationships