URLRequest
extension URLRequest
extension URLRequest: URLRequestConvertible
-
Returns
allHTTPHeaderFields
asHTTPHeaders
.Declaration
Swift
public var headers: HTTPHeaders { get set }
-
Returns
self
.Declaration
Swift
public func asURLRequest() throws -> URLRequest
-
Declaration
Swift
public init(url: any URLConvertible, method: HTTPMethod, headers: HTTPHeaders? = nil) throws
Parameters
url
The
URLConvertible
value.method
The
HTTPMethod
.headers
The
HTTPHeaders
,nil
by default. -
Returns the
httpMethod
as Alamofire’sHTTPMethod
type.Declaration
Swift
public var method: HTTPMethod? { get set }
-
Undocumented
Declaration
Swift
public func validate() throws