Skip to content
This repository has been archived by the owner on Oct 17, 2021. It is now read-only.

URLEncodedFormEncoder_DateEncoding

mattt edited this page Sep 18, 2020 · 2 revisions

URLEncodedFormEncoder.DateEncoding

Encoding to use for Date values.

public enum DateEncoding

Enumeration Cases

deferredToDate

Defers encoding to the Date type. This is the default encoding.

case deferredToDate

secondsSince1970

Encodes Dates as seconds since midnight UTC on January 1, 1970.

case secondsSince1970

millisecondsSince1970

Encodes Dates as milliseconds since midnight UTC on January 1, 1970.

case millisecondsSince1970

iso8601

Encodes Dates according to the ISO8601 and RFC3339 standards.

case iso8601

formatted

Encodes Dates using the given DateFormatter.

case formatted(:​ DateFormatter)

custom

Encodes Dates using the given closure.

case custom(:(Date) throws -> String)
Types
Protocols
Global Typealiases
Clone this wiki locally