DateEncodingStrategy
public enum DateEncodingStrategyEnum representing the various strategies for encoding Dates.
As per the BSON specification, the default strategy is to encode Dates as BSON datetime objects.
See also
bsonspec.org- 
                  
                  Encode the Dateby deferring to its default encoding implementation.DeclarationSwift case deferredToDate
- 
                  
                  Encode the Dateas a BSON datetime object (default).DeclarationSwift case bsonDateTime
- 
                  
                  Encode the Dateas a 64-bit integer counting the number of milliseconds since January 1, 1970.DeclarationSwift case millisecondsSince1970
- 
                  
                  Encode the Dateas a BSON double counting the number of seconds since January 1, 1970.DeclarationSwift case secondsSince1970
- 
                  
                  Encode the Dateas an ISO-8601-formatted string (in RFC 339 format).DeclarationSwift case iso8601
- 
                  
                  Encode the Dateas a string formatted by the given formatter.DeclarationSwift case formatted(DateFormatter)
- 
                  
                  Encode the Dateby using the given closure. If the closure does not encode a value, an empty document will be encoded in its place.DeclarationSwift case custom((Date, Encoder) throws -> Void)
 View on GitHub
            View on GitHub
           Install in Dash
            Install in Dash
           DateEncodingStrategy Enumeration Reference
      DateEncodingStrategy Enumeration Reference