AnyRequestAdapterobject with a closure.
public init(_ block: @escaping (URLRequest) throws -> URLRequest)
A closure to be invoked with an input
Adapts an input
URLRequestobject and returns a modified object.
ThrowsAn error during the adapting process.
NoteThis method just invokes
blockreceived from the initializer.
public func adapted(_ request: URLRequest) throws -> URLRequest
The request to be adapted.