Configuration
public struct Configuration
Used to capture URLForm Coding Configuration used for decoding
-
Supported date formats
See moreDeclaration
Swift
public enum DateDecodingStrategy
-
Creates a new
URLEncodedFormCodingConfiguration
.Declaration
Swift
public init( boolFlags: Bool = true, arraySeparators: [Character] = [",", "|"], dateDecodingStrategy: DateDecodingStrategy = .secondsSince1970 )
Parameters
boolFlags
Set to
true
allows you to parseflag1&flag2
as boolean variables where object with variableflag1
andflag2
would decode totrue
orfalse
depending on if the value was present or not. If this flag is set to true, it will always resolve for an optionalBool
.arraySeparators
Uses these characters to decode arrays. If set to
,
,arr=v1,v2
would populate a key namedarr
of typeArray
to be decoded as["v1", "v2"]
dateDecodingStrategy
Date format used to decode a date. Date formats are tried in the order provided