Class JsonHandler

java.lang.Object
com.prineside.tdi2.utils.JsonHandler

public final class JsonHandler extends Object
  • Field Details

    • EMPTY_JSON_OBJECT

      public static final JsonValue EMPTY_JSON_OBJECT
  • Method Details

    • i

      public static JsonHandler i()
    • getMapper

      public com.fasterxml.jackson.databind.json.JsonMapper getMapper()
    • orEmptyObject

      public static JsonValue orEmptyObject(@Null JsonValue v)
    • isJsonFile

      public static boolean isJsonFile(FileHandle fh)
      Does not validate the Json file contents, only checks if it is an existing file with one of the json extensions in name
      Returns:
      true if file exists, is not a directory and has a json extension (.json / .json5 etc)
    • cloneJsonValue

      public static JsonValue cloneJsonValue(JsonValue value)
    • setJsonValue

      public static void setJsonValue(JsonValue what, JsonValue toWhat)
      Modifies 'what' in place.