Table of Contents

Class Serializer

Namespace
Mech3DotNet.Exchange
Assembly
Mech3DotNet.dll

Mech3ax exchange format serializer.

public class Serializer
Inheritance
Serializer
Inherited Members

Constructors

Serializer(Writer, List<TypeConverter>)

public Serializer(Writer w, List<TypeConverter> genericConverters)

Parameters

w Writer
genericConverters List<TypeConverter>

Methods

SerializeBool(bool)

public void SerializeBool(bool v)

Parameters

v bool

SerializeBytes(byte[])

public void SerializeBytes(byte[] v)

Parameters

v byte[]

SerializeDateTime(DateTime)

public void SerializeDateTime(DateTime v)

Parameters

v DateTime

SerializeF32(float)

public void SerializeF32(float v)

Parameters

v float

SerializeFieldName(string)

public void SerializeFieldName(string v)

Parameters

v string

SerializeGeneric<T>()

public Action<T> SerializeGeneric<T>() where T : notnull

Returns

Action<T>

Type Parameters

T

SerializeI16(short)

public void SerializeI16(short v)

Parameters

v short

SerializeI32(int)

public void SerializeI32(int v)

Parameters

v int

SerializeI8(sbyte)

public void SerializeI8(sbyte v)

Parameters

v sbyte

SerializeNewTypeVariant(uint)

public void SerializeNewTypeVariant(uint variantIndex)

Parameters

variantIndex uint

SerializeRefOption<T>(Action<T>)

public Action<T?> SerializeRefOption<T>(Action<T> write) where T : class

Parameters

write Action<T>

Returns

Action<T>

Type Parameters

T

SerializeString(string)

public void SerializeString(string v)

Parameters

v string

SerializeStruct(ulong)

public void SerializeStruct(ulong len)

Parameters

len ulong

SerializeU16(ushort)

public void SerializeU16(ushort v)

Parameters

v ushort

SerializeU32(uint)

public void SerializeU32(uint v)

Parameters

v uint

SerializeU64(ulong)

public void SerializeU64(ulong v)

Parameters

v ulong

SerializeU8(byte)

public void SerializeU8(byte v)

Parameters

v byte

SerializeUnitVariant(uint)

public void SerializeUnitVariant(uint variantIndex)

Parameters

variantIndex uint

SerializeValOption<T>(Action<T>)

public Action<T?> SerializeValOption<T>(Action<T> write) where T : struct

Parameters

write Action<T>

Returns

Action<T?>

Type Parameters

T

SerializeVec<T>(Action<T>)

public Action<List<T>> SerializeVec<T>(Action<T> write)

Parameters

write Action<T>

Returns

Action<List<T>>

Type Parameters

T

Serialize<T>(TypeConverter<T>)

public Action<T> Serialize<T>(TypeConverter<T> converter)

Parameters

converter TypeConverter<T>

Returns

Action<T>

Type Parameters

T