Пример #1
0
 /// <summary>
 /// Create a human readable string from the JSON.
 /// </summary>
 /// <param name="input">The JSON string to be beautified.</param>
 /// <param name="decodeUnicode">Indicates whether \uXXXX encoded Unicode notations should be converted into actual Unicode characters.</param>
 /// <returns>A pretty-printed JSON string.</returns>
 public static string Beautify(string input, bool decodeUnicode)
 {
     return(Formatter.PrettyPrint(input, decodeUnicode));
 }
Пример #2
0
 /// <summary>
 /// Creates a minified string from the JSON.
 /// </summary>
 /// <param name="input">The JSON string to be minified.</param>
 /// <returns>A minified JSON string.</returns>
 public static string Minify(string input)
 {
     return(Formatter.UglyPrint(input));
 }
Пример #3
0
 /// <summary>
 /// Creates a human readable string from the JSON.
 /// </summary>
 /// <param name="input">The JSON string to be beautified.</param>
 /// <returns>A pretty-printed JSON string.</returns>
 public static string Beautify(string input)
 {
     return(Formatter.PrettyPrint(input));
 }