Class JSONTypeError

All Implemented Interfaces:
Serializable

public class JSONTypeError extends JSONSchemaError
Signalled to indicate a violation of a type constraint. For example, the program may be expecting a JSON number, only to be given a JSON array.
See Also:
  • Field Details

    • expected

      protected Class<?>[] expected
    • actual

      protected Object actual
  • Constructor Details

    • JSONTypeError

      public JSONTypeError(Class<?> expected, Object actual)
    • JSONTypeError

      public JSONTypeError(Class<?>[] expected, Object actual)
  • Method Details

    • getExpected

      public Class<?>[] getExpected()
    • getActual

      public Object getActual()
    • formatClassList

      protected static String formatClassList(Class<?>[] classes)