KeyedDecodingContainer
extension KeyedDecodingContainer
-
Attempt to extract a value from a container. If it fails, just return a wrapped default value of the right type.
Declaration
Swift
func decode<T>(_ type: DecodableDefault.Wrapper<T>.Type, forKey key: Key) throws -> DecodableDefault.Wrapper<T>
Parameters
type
the type to decode
key
the key to use in the container