RequestOptions

@objc
public class RequestOptions : NSObject, NSCopying

Per-request options. This class allows specifying options at the request level, overriding default options at the Client level.

Note

These are reserved for advanced use cases. In most situations, they shouldn’t be needed.
  • HTTP headers, as untyped values.

    Declaration

    Swift

    @objc
    public var headers: [String : String]
  • URL parameters, as untyped values. These will go into the query string part of the URL (after the question mark).

    Declaration

    Swift

    @objc
    public var urlParameters: [String : String]
  • Construct request options.

    • param headers: HTTP headers (default: empty).
    • param urlParameters: URL parameters (default: empty).

    Declaration

    Swift

    @objc
    public init(headers: [String: String] = [:], urlParameters: [String: String] = [:])
  • Support for NSCopying.

    Declaration

    Swift

    @objc
    open func copy(with zone: NSZone?) -> Any