SerializationExtensions.SerializeToJson Method

Namespace:
Weavy.Core.Helpers
Assembly:
Weavy.Core.dll

SerializeToJson(Object, Nullable, JsonSerializerSettings)

Serializes an object, or graph of connected objects, to a json string.

Uses JSON.NET.

public static string SerializeToJson(this object graph, Formatting? formatting = default(Formatting? ), JsonSerializerSettings settings = null)

Parameters

graph
System.Object
formatting
System.Nullable{Newtonsoft.Json.Formatting}
settings
Newtonsoft.Json.JsonSerializerSettings

Returns

System.String

A json representation of the graph.