Class UuidJsonConverter
Namespace: Void.Minecraft.Profiles.Serializers
Assembly: Void.Minecraft.dll
public class UuidJsonConverter : JsonConverter<Uuid>Inheritance
object ← JsonConverter ← JsonConverter<Uuid> ← UuidJsonConverter
Inherited Members
JsonConverter<Uuid>.CanConvert(Type), JsonConverter<Uuid>.Read(ref Utf8JsonReader, Type, JsonSerializerOptions), JsonConverter<Uuid>.ReadAsPropertyName(ref Utf8JsonReader, Type, JsonSerializerOptions), JsonConverter<Uuid>.Write(Utf8JsonWriter, Uuid, JsonSerializerOptions), JsonConverter<Uuid>.WriteAsPropertyName(Utf8JsonWriter, Uuid, JsonSerializerOptions), JsonConverter<Uuid>.HandleNull, JsonConverter<Uuid>.Type, JsonConverter.CanConvert(Type), JsonConverter.Type, object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.MemberwiseClone(), object.ReferenceEquals(object?, object?), object.ToString()
Methods
Read(ref Utf8JsonReader, Type, JsonSerializerOptions)
Reads and converts the JSON to type
public override Uuid Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options)Parameters
reader Utf8JsonReader
The reader.
typeToConvert Type
The type to convert.
options JsonSerializerOptions
An object that specifies serialization options to use.
Returns
The converted value.
ReadAsPropertyName(ref Utf8JsonReader, Type, JsonSerializerOptions)
Reads a dictionary key from a JSON property name.
public override Uuid ReadAsPropertyName(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options)Parameters
reader Utf8JsonReader
The
typeToConvert Type
The type to convert.
options JsonSerializerOptions
The options to use when reading the value.
Returns
The value that was converted.
Write(Utf8JsonWriter, Uuid, JsonSerializerOptions)
Writes a specified value as JSON.
public override void Write(Utf8JsonWriter writer, Uuid value, JsonSerializerOptions options)Parameters
writer Utf8JsonWriter
The writer to write to.
value Uuid
The value to convert to JSON.
options JsonSerializerOptions
An object that specifies serialization options to use.
WriteAsPropertyName(Utf8JsonWriter, Uuid, JsonSerializerOptions)
Writes a dictionary key as a JSON property name.
public override void WriteAsPropertyName(Utf8JsonWriter writer, Uuid value, JsonSerializerOptions options)Parameters
writer Utf8JsonWriter
The
value Uuid
The value to convert. The value of
options JsonSerializerOptions
The options to use when writing the value.