SingleValueDecodingContainer
A container that can support the storage and direct decoding of a single nonkeyed value.
protocol SingleValueDecodingContainer
Browse conforming typesA container that can support the storage and direct decoding of a single nonkeyed value.
protocol SingleValueDecodingContainer
import Swift
var codingPath: [any CodingKey] { get }
The path of coding keys taken to get to this point in encoding.
func decode(_ type: String.Type) throws -> String
Decodes a single value of the given type.
func decode(_ type: Bool.Type) throws -> Bool
Decodes a single value of the given type.
func decode(_ type: Double.Type) throws -> Double
Decodes a single value of the given type.
func decode(_ type: Float.Type) throws -> Float
Decodes a single value of the given type.
func decode(_ type: Int.Type) throws -> Int
Decodes a single value of the given type.
func decode(_ type: UInt.Type) throws -> UInt
Decodes a single value of the given type.
func decode<T>(_ type: T.Type) throws -> T where T : Decodable
Decodes a single value of the given type.
func decode(_ type: Int8.Type) throws -> Int8
Decodes a single value of the given type.
func decode(_ type: Int16.Type) throws -> Int16
Decodes a single value of the given type.
func decode(_ type: Int32.Type) throws -> Int32
Decodes a single value of the given type.
func decode(_ type: Int64.Type) throws -> Int64
Decodes a single value of the given type.
func decode(_ type: UInt8.Type) throws -> UInt8
Decodes a single value of the given type.
func decode(_ type: Int128.Type) throws -> Int128
Decodes a single value of the given type.
func decode(_ type: UInt16.Type) throws -> UInt16
Decodes a single value of the given type.
func decode(_ type: UInt32.Type) throws -> UInt32
Decodes a single value of the given type.
func decode(_ type: UInt64.Type) throws -> UInt64
Decodes a single value of the given type.
func decode(_ type: UInt128.Type) throws -> UInt128
Decodes a single value of the given type.
func decodeNil() -> Bool
Decodes a null value.
func decode(_ type: Int128.Type) throws -> Int128
func decode(_ type: UInt128.Type) throws -> UInt128
protocol UnkeyedDecodingContainer
A type that provides a view into a decoder’s storage and is used to hold the encoded properties of a decodable type sequentially, without keys.
func decode(_ type: Int128.Type) throws -> Int128
func decode(_ type: UInt128.Type) throws -> UInt128