Required Instance Methodswift 6.0.3Swift

decode(_:)

Decodes a value of the given type.

iOS
18.0+
macOS
15.0+
tvOS
18.0+
visionOS
2.0+
watchOS
11.0+
mutating func decode(_ type: UInt128.Type) throws -> UInt128

Parameters

type

The type of value to decode.

Returns

A value of the requested type, if present for the given key and convertible to the requested type.

Throws

DecodingError.typeMismatch if the encountered encoded value is not convertible to the requested type.

DecodingError.valueNotFound if the encountered encoded value is null, or of there are no more values to decode.