DefaultEnumCodable
public protocol DefaultEnumCodable : Decodable, Encodable, RawRepresentable
A data structure that can be parsed to a RawRepresentable
type, with a default case to be used if the received
data cannot be represented by any value in the type.
-
The default value to use when the parsing fails due to the received data not being representable by any value in the type.
Declaration
Swift
static var defaultCase: Self { get }