Skip to main content

Class MicroJsonSerializer

An implementation of IJsonSerializer that uses MicroJson

Assembly: Meadow.dll
View Source
Declaration
public class MicroJsonSerializer : IJsonSerializer

Implements:
Meadow.IJsonSerializer

Methods

Deserialize<T>(string)

Deserializes a provided string into a typed object

View Source
Declaration
public T Deserialize<T>(string json)
Returns

<T>: An instance of T

Parameters
TypeNameDescription
System.StringjsonThe source JSON
Type Parameters
NameDescription
TThe type to deserialize to

Deserialize(string, Type)

Deserializes a provided string into a typed object

View Source
Declaration
public object Deserialize(string json, Type type)
Returns

System.Object: An instance of 'type'

Parameters
TypeNameDescription
System.StringjsonThe source JSON
System.TypetypeThe type to deserialize to

Serialize(object)

Serializes an object to a JSON representation

View Source
Declaration
public string? Serialize(object source)
Returns

System.String: A JSON representationof the source object

Parameters
TypeNameDescription
System.ObjectsourceAn object to serialize

Implements