code: private static JsonArray getJsonValueAsArray(JsonValue value) {
          return (value != null && value.getValueType() == ValueType.ARRAY) ? value.asJsonArray() : null;
      }
docs: Returns the specified JsonValue as a JsonArray, or null if it's not an array