Skip to main content

CrsConverter

Namespace: Meshmakers.Octo.Runtime.Contracts.Geospatial.Converters

Converter for System.Text.Json and YamlDotNet for ICRSObject

public class CrsConverter : JsonConverter<ICRSObject>, IYamlTypeConverter

Inheritance Object → JsonConverter → JsonConverter<ICRSObject> → CrsConverter
Implements IYamlTypeConverter

Properties

HandleNull

public bool HandleNull { get; }

Property Value

Boolean

Type

public Type Type { get; }

Property Value

Type

Constructors

CrsConverter()

public CrsConverter()

Methods

Read(out Utf8JsonReader, Type, JsonSerializerOptions)

public ICRSObject Read(out Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options)

Parameters

reader Utf8JsonReader

typeToConvert Type

options JsonSerializerOptions

Returns

ICRSObject

Write(Utf8JsonWriter, ICRSObject, JsonSerializerOptions)

public void Write(Utf8JsonWriter writer, ICRSObject value, JsonSerializerOptions options)

Parameters

writer Utf8JsonWriter

value ICRSObject

options JsonSerializerOptions

Accepts(Type)

public bool Accepts(Type type)

Parameters

type Type

Returns

Boolean

ReadYaml(IParser, Type, ObjectDeserializer)

public object ReadYaml(IParser parser, Type type, ObjectDeserializer rootDeserializer)

Parameters

parser IParser

type Type

rootDeserializer ObjectDeserializer

Returns

Object

WriteYaml(IEmitter, Object, Type, ObjectSerializer)

public void WriteYaml(IEmitter emitter, object value, Type type, ObjectSerializer rootSerializer)

Parameters

emitter IEmitter

value Object

type Type

rootSerializer ObjectSerializer