public enum JsonSyntaxError extends Enum<JsonSyntaxError>
JsonSyntaxError describes the kinds of syntax error a JSON parser
may encounter.| Enum Constant and Description |
|---|
INVALID_ARRAY_FIRST
Describes an invalid JSON array, where the initial [ isn't
followed by a JSON value or a ].
|
INVALID_ARRAY_FOLLOW
Describes an invalid JSON array, where a value isn't followed by a JSON
, or a ].
|
INVALID_ARRAY_VALUE
Describes an invalid JSON array, where a , isn't followed by a
JSON value.
|
INVALID_DOCUMENT_END
Describes an invalid document, where the the last } or
] is followed by further non-whitespace characters.
|
INVALID_DOCUMENT_START
Describes an invalid document, where the initial character is neither
{ nor [.
|
INVALID_ESCAPE_SEQUENCE
Describes an invalid JSON string, where a \\ isn't followed by a
valid escape sequence.
|
INVALID_LITERAL
Describes an invalid JSON value, that does't begin with [,
{ or " and isn't a valid JSON literal.
|
INVALID_OBJECT_FIRST
Describes an invalid JSON object, where the initial { isn't
followed by a JSON name or a }.
|
INVALID_OBJECT_FOLLOW
Describes an invalid JSON object, where a value isn't followed by a
. or a }.
|
INVALID_OBJECT_NAME
Describes an invalid JSON object, where a , isn't followed by a
JSON name.
|
INVALID_OBJECT_SEPARATION
Describes an invalid JSON object, where a JSON name isn't followed by a
:.
|
INVALID_OBJECT_VALUE
Describes an invalid JSON object, where a : isn't followed by a
JSON value.
|
INVALID_UNICODE_ESCAPE_SEQUENCE
Describes an invalid JSON string, where a \\u isn't followed by
four hex characters.
|
UNFINISHED_ESCAPE_SEQUENCE
Describes an invalid JSON string, where a \ isn't followed by at
least one character.
|
UNFINISHED_UNICODE_ESCAPE_SEQUENCE
Describes an invalid JSON string, where a \\u isn't followed by
four character.
|
UNTERMINATED_STRING
Describes an invalid JSON string, that is not ended by a ".
|
| Modifier and Type | Method and Description |
|---|---|
String |
getDescription()
Returns a description of this
JsonSyntaxError. |
String |
getExpectation()
Returns a description of an unfulfilled expectation, that caused this
JsonSyntaxError. |
static JsonSyntaxError |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static JsonSyntaxError[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final JsonSyntaxError INVALID_DOCUMENT_START
public static final JsonSyntaxError INVALID_DOCUMENT_END
public static final JsonSyntaxError INVALID_ARRAY_FIRST
public static final JsonSyntaxError INVALID_ARRAY_FOLLOW
public static final JsonSyntaxError INVALID_ARRAY_VALUE
public static final JsonSyntaxError INVALID_OBJECT_FIRST
public static final JsonSyntaxError INVALID_OBJECT_FOLLOW
public static final JsonSyntaxError INVALID_OBJECT_NAME
public static final JsonSyntaxError INVALID_OBJECT_SEPARATION
public static final JsonSyntaxError INVALID_OBJECT_VALUE
public static final JsonSyntaxError UNTERMINATED_STRING
public static final JsonSyntaxError UNFINISHED_ESCAPE_SEQUENCE
public static final JsonSyntaxError INVALID_ESCAPE_SEQUENCE
public static final JsonSyntaxError UNFINISHED_UNICODE_ESCAPE_SEQUENCE
public static final JsonSyntaxError INVALID_UNICODE_ESCAPE_SEQUENCE
public static final JsonSyntaxError INVALID_LITERAL
public static JsonSyntaxError[] values()
for (JsonSyntaxError c : JsonSyntaxError.values()) System.out.println(c);
public static JsonSyntaxError valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic String getDescription()
JsonSyntaxError.JsonSyntaxError.public String getExpectation()
JsonSyntaxError.JsonSyntaxError.Copyright © 2016 Markenwerk – Gesellschaft für markenbildende Maßnahmen mbH. All rights reserved.