static enum SimpleJsonWriter.State extends java.lang.Enum<SimpleJsonWriter.State>
Enum Constant and Description |
---|
FirstKey
Expects first key in an object.
|
FirstValue
Expects a value after a key or the first value in an array.
|
Key
Expects further key in an object.
|
None
State after all open environments are closed.
|
Relaxed
Special start state which allows JSON output which starts with
a key or a value.
|
Value
Expects followup value in an array.
|
Modifier and Type | Field and Description |
---|---|
(package private) boolean |
allowsKey |
(package private) boolean |
allowsValue |
Modifier and Type | Method and Description |
---|---|
(package private) abstract SimpleJsonWriter.State |
advance(java.util.Stack<Json.Env> stack)
Advance to the next state.
|
(package private) abstract boolean |
needsSeparator(java.util.Stack<Json.Env> stack)
Is a separator required?
|
static SimpleJsonWriter.State |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static SimpleJsonWriter.State[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final SimpleJsonWriter.State Relaxed
public static final SimpleJsonWriter.State None
public static final SimpleJsonWriter.State FirstValue
public static final SimpleJsonWriter.State Value
public static final SimpleJsonWriter.State FirstKey
public static final SimpleJsonWriter.State Key
public static SimpleJsonWriter.State[] values()
for (SimpleJsonWriter.State c : SimpleJsonWriter.State.values()) System.out.println(c);
public static SimpleJsonWriter.State valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null@NotNull abstract SimpleJsonWriter.State advance(@NotNull java.util.Stack<Json.Env> stack)
stack
- current environment stack