public static enum JsonWriter.OutputType extends java.lang.Enum<JsonWriter.OutputType>
| Enum Constant and Description |
|---|
javascript
Like JSON, but names are only double quoted if necessary.
|
json
Normal JSON, with all its double quotes.
|
minimal
Like JSON, but:
Names only require double quotes if they start with
space or any of ":,}/ or they contain
// or /* or :. |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
quoteName(java.lang.String value) |
java.lang.String |
quoteValue(java.lang.Object value) |
static JsonWriter.OutputType |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static JsonWriter.OutputType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final JsonWriter.OutputType json
public static final JsonWriter.OutputType javascript
public static final JsonWriter.OutputType minimal
space or any of ":,}/ or they contain
// or /* or :.
space or any of ":,{[]/ or they
contain // or /* or any of }], or they are equal to true,
false , or null.
//... or /*...*/
public static JsonWriter.OutputType[] values()
for (JsonWriter.OutputType c : JsonWriter.OutputType.values()) System.out.println(c);
public static JsonWriter.OutputType 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 nullpublic java.lang.String quoteValue(java.lang.Object value)
public java.lang.String quoteName(java.lang.String value)