 
 /// Custom session delegate class for URLSession's callbacks and operations.
 public final class SessionDelegate: NSObject {
+    // MARK: - URLSessionDelegate closures.
+    
     /// Closure for `urlSession(_:didBecomeInvalidWithError:)` function in protocol `URLSessionDelegate`.
     public var sessionDidBecomeInvalid: SessionDidBecomeInvalid?
     /// Closure for `urlSession(_:didReceive:completionHandler:)` function in protocol `URLSessionDelegate`.

    /// Closure for `urlSession(_:task:didSendBodyData:totalBytesSent:totalBytesExpectedToSend:)` function in protocol `URLSessionTaskDelegate`.
    public var taskOfSessionDidSendData: TaskOfSessionDidSendData?
    /// Closure for `urlSession(_:task:didFinishCollecting:)` function in protocol `URLSessionTaskDelegate`.
    public var taskOfSessionDidFinishCollecting: TaskOfSessionDidFinishCollecting?
    /// Closure for `urlSession(_:task:didComplete:)` function in protocol `URLSessionTaskDelegate`.
    public var taskOfSessionDidComplete: TaskOfSessionDidComplete?
    

    /// - Parameters:
    ///   - session:    The session containing the stream task that closed writes.
    ///   - streamTask: The stream task that closed writes.
    public func urlSession(_ session: URLSession, writeClosedFor streamTask: URLSessionStreamTask) {
        streamTaskOfSessionWriteClosed?(streamTask, session)
    }
