Class JsonUtil
Helper utilities for reading and writing JSON files.
public static class JsonUtil
- Inheritance
-
JsonUtil
- Inherited Members
Methods
CallJsonArrayByPath(JsonObject, IEnumerable<string>)
public static JsonArray CallJsonArrayByPath(this JsonObject srcdst, IEnumerable<string> jsonObjectPath)
Parameters
srcdstJsonObjectjsonObjectPathIEnumerable<string>
Returns
CallJsonObjectByPath(JsonObject, IEnumerable<string>)
public static JsonObject CallJsonObjectByPath(this JsonObject srcdst, IEnumerable<string> jsonObjectPath)
Parameters
srcdstJsonObjectjsonObjectPathIEnumerable<string>
Returns
WritePartialJson<TConfig>(string, string, TConfig)
Writes a config object into a named section of a JSON file; merges when file exists and overwrites the same section name.
public static void WritePartialJson<TConfig>(string filePath, string configName, TConfig config)
Parameters
filePathstringJSON file path
configNamestringSection name to write
configTConfigSection object to write
Type Parameters
TConfigType of the config object