Structures
The following structures are available globally.
-
Type that acts as a generic extension point for all
See moreAlamofireExtendedtypes.Declaration
Swift
public struct AlamofireExtension<ExtendedType> -
See moreResponseCacheris a convenienceCachedResponseHandlermaking it easy to cache, not cache, or modify a cached response.Declaration
-
An order-preserving and case-insensitive representation of HTTP headers.
See moreDeclaration
Swift
public struct HTTPHeadersextension HTTPHeaders: ExpressibleByDictionaryLiteralextension HTTPHeaders: ExpressibleByArrayLiteralextension HTTPHeaders: Sequenceextension HTTPHeaders: Collectionextension HTTPHeaders: CustomStringConvertible
-
A representation of a single HTTP header’s name / value pair.
See moreDeclaration
Swift
public struct HTTPHeader : Hashableextension HTTPHeader: CustomStringConvertible -
Type representing HTTP methods. Raw
Stringvalue is stored and compared case-sensitively, soHTTPMethod.get != HTTPMethod(rawValue: "get").See https://tools.ietf.org/html/rfc7231#section-4.3
See moreDeclaration
Swift
public struct HTTPMethod : RawRepresentable, Equatable, Hashable
-
Creates a url-encoded query string to be set as or appended to any existing URL query string or set as the HTTP body of the URL request. Whether the query string is set or appended to any existing URL query string or set as the HTTP body depends on the destination of the encoding.
The
Content-TypeHTTP header field of an encoded request with HTTP body is set toapplication/x-www-form-urlencoded; charset=utf-8.There is no published specification for how to encode collection types. By default the convention of appending
[]to the key for array values (foo[]=1&foo[]=2), and appending the key surrounded by square brackets for nested dictionary values (foo[bar]=baz) is used. Optionally,ArrayEncodingcan be used to omit the square brackets appended to array keys.
See moreBoolEncodingcan be used to configure how boolean values are encoded. The default behavior is to encodetrueas 1 andfalseas 0.Declaration
Swift
public struct URLEncoding : ParameterEncoding -
Uses
See moreJSONSerializationto create a JSON representation of the parameters object, which is set as the body of the request. TheContent-TypeHTTP header field of an encoded request is set toapplication/json.Declaration
Swift
public struct JSONEncoding : ParameterEncoding -
See moreRedirectoris a convenienceRedirectHandlermaking it easy to follow, not follow, or modify a redirect.Declaration
-
Type used to store all values associated with a serialized response of a
See moreDataRequestorUploadRequest.Declaration
Swift
public struct DataResponse<Success, Failure> where Failure : Errorextension DataResponse: CustomStringConvertible, CustomDebugStringConvertible -
Used to store all data associated with a serialized response of a download request.
See moreDeclaration
Swift
public struct DownloadResponse<Success, Failure> where Failure : Errorextension DownloadResponse: CustomStringConvertible, CustomDebugStringConvertible
-
See moreDataPreprocessorthat returns passedDatawithout any transform.Declaration
Swift
public struct PassthroughPreprocessor : DataPreprocessor -
See moreDataPreprocessorthat trims Google’s typical)]}',\nXSSI JSON header.Declaration
Swift
public struct GoogleXSSIPreprocessor : DataPreprocessor
-
Type representing an empty response. Use
See moreEmpty.valueto get the static instance.Declaration
View on GitHub
Install in Dash
Structures Reference