Kingfisher Documentation

Class Session​Delegate

@objc(KFSessionDelegate) // Fix for ObjC header name conflicting. https://github.com/onevcat/Kingfisher/issues/1530
open class SessionDelegate: NSObject  
%275 SessionDelegate SessionDelegate URLSessionDataDelegate URLSessionDataDelegate SessionDelegate->URLSessionDataDelegate NSObject NSObject SessionDelegate->NSObject

Conforms To

NSObject
URLSessionDataDelegate

Methods

url​Session(_:​data​Task:​did​Receive:​completion​Handler:​)

open func urlSession(
        _ session: URLSession,
        dataTask: URLSessionDataTask,
        didReceive response: URLResponse,
        completionHandler: @escaping (URLSession.ResponseDisposition) -> Void) 

url​Session(_:​data​Task:​did​Receive:​)

open func urlSession(_ session: URLSession, dataTask: URLSessionDataTask, didReceive data: Data)  

url​Session(_:​task:​did​Complete​With​Error:​)

open func urlSession(_ session: URLSession, task: URLSessionTask, didCompleteWithError error: Error?)  

url​Session(_:​did​Receive:​completion​Handler:​)

open func urlSession(
        _ session: URLSession,
        didReceive challenge: URLAuthenticationChallenge,
        completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) 

url​Session(_:​task:​did​Receive:​completion​Handler:​)

open func urlSession(
        _ session: URLSession,
        task: URLSessionTask,
        didReceive challenge: URLAuthenticationChallenge,
        completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) 

url​Session(_:​task:​will​Perform​HTTPRedirection:​new​Request:​completion​Handler:​)

open func urlSession(
        _ session: URLSession,
        task: URLSessionTask,
        willPerformHTTPRedirection response: HTTPURLResponse,
        newRequest request: URLRequest,
        completionHandler: @escaping (URLRequest?) -> Void)