RequestManager
open class RequestManager : @unchecked Sendable
请求管理器
-
Undocumented
Declaration
Swift
public static let shared: RequestManager
-
Undocumented
Declaration
Swift
public init()
-
添加请求并开始
Declaration
Swift
open func addRequest(_ request: HTTPRequest)
-
取消已经添加的请求
Declaration
Swift
open func cancelRequest(_ request: HTTPRequest)
-
取消所有已添加的请求
Declaration
Swift
open func cancelAllRequests()
-
构建请求URL
Declaration
Swift
open func buildRequestUrl(for request: HTTPRequest) -> URL
-
过滤URL请求
Declaration
Swift
open func filterUrlRequest(_ urlRequest: inout URLRequest, for request: HTTPRequest)
-
获取响应编码
Declaration
Swift
open func stringEncoding(for request: HTTPRequest) -> String.Encoding
-
获取下载路径的临时路径
Declaration
Swift
open func incompleteDownloadTempPath(for request: HTTPRequest, downloadPath: String?) -> URL?