Deserialize(String, Type, YamlSerializerContext) Method

Definition

Namespace SharpYaml
Assembly SharpYaml.dll

Deserializes a YAML payload into an explicit destination type using generated metadata from a serializer context.

public static object? Deserialize(string yaml, Type returnType, YamlSerializerContext context)

Parameters

yaml
String

The YAML payload.

returnType
Type

The destination CLR type.

context
YamlSerializerContext

The source-generated serializer context.

Returns

Object
The deserialized value.