Skip to content

_struct(__)

MarcoDotIO edited this page Jul 20, 2023 · 1 revision

_struct(_:)

Deserialize a structure that conforms to the KeyProtocol from the Deserializer's input data buffer.

public static func _struct<T: KeyProtocol>(_ deserializer: Deserializer) throws -> T 

This function uses the type's deserialize(from:) method, passing the current Deserializer instance, to deserialize the structure from the input data buffer.

Parameters

  • type: The type of the structure that conforms to KeyProtocol to be deserialized.

Throws

Any error that may occur during the deserialization process, such as reading the input data or decoding the structure.

Returns

An instance of type T deserialized from the input data buffer.

Types
Protocols
Global Variables
Global Functions
Extensions
Clone this wiki locally