Package com.kazurayam.materialstore.util
Class JsonUtil
java.lang.Object
com.kazurayam.materialstore.util.JsonUtil
-
Field Summary
Modifier and TypeFieldDescriptionstatic final Pattern
Given with an Exception: Caused by: com.google.gson.stream.MalformedJsonException: Expected ':' at line 1 column 8 path $..8 log the following: line ---------1---------2--- ... -
Method Summary
Modifier and TypeMethodDescriptionstatic String
escapeAsJsonString
(String value) static void
logJsonSyntaxException
(String json, com.google.gson.JsonSyntaxException e, org.slf4j.Logger logger) static String
prettyPrint
(String sourceJson) static <T> String
prettyPrint
(String sourceJson, Class<T> clazz)
-
Field Details
-
LINE_COLUMN_PATTERN
Given with an Exception: Caused by: com.google.gson.stream.MalformedJsonException: Expected ':' at line 1 column 8 path $..8 log the following: line ---------1---------2--- ... --9---------0---------1--- ... 1 { "foo", "bar" } ^
-
-
Method Details
-
escapeAsJsonString
-
prettyPrint
-
prettyPrint
-
logJsonSyntaxException
public static void logJsonSyntaxException(String json, com.google.gson.JsonSyntaxException e, org.slf4j.Logger logger) throws IOException - Throws:
IOException
-