public class JsonWriteContext extends JsonStreamContext
JsonStreamContext, which implements
core methods needed, and also exposes
more complete API to generator implementation classes.| 限定符和类型 | 字段和说明 |
|---|---|
static int |
STATUS_EXPECT_NAME |
static int |
STATUS_EXPECT_VALUE |
static int |
STATUS_OK_AFTER_COLON |
static int |
STATUS_OK_AFTER_COMMA |
static int |
STATUS_OK_AFTER_SPACE |
static int |
STATUS_OK_AS_IS |
| 限定符和类型 | 方法和说明 |
|---|---|
JsonWriteContext |
createChildArrayContext() |
JsonWriteContext |
createChildObjectContext() |
static JsonWriteContext |
createRootContext() |
String |
getCurrentName()
Method for accessing name associated with the current location.
|
JsonWriteContext |
getParent()
Accessor for finding parent context of this context; will
return null for root context.
|
String |
toString()
Overridden to provide developer writeable "JsonPath" representation
of the context.
|
int |
writeFieldName(String name)
Method that writer is to call before it writes a field name.
|
int |
writeValue() |
getCurrentIndex, getEntryCount, getTypeDesc, inArray, inObject, inRootpublic static final int STATUS_OK_AS_IS
public static final int STATUS_OK_AFTER_COMMA
public static final int STATUS_OK_AFTER_COLON
public static final int STATUS_OK_AFTER_SPACE
public static final int STATUS_EXPECT_VALUE
public static final int STATUS_EXPECT_NAME
public static JsonWriteContext createRootContext()
public final JsonWriteContext createChildArrayContext()
public final JsonWriteContext createChildObjectContext()
public final JsonWriteContext getParent()
JsonStreamContextgetParent 在类中 JsonStreamContextpublic final String getCurrentName()
JsonStreamContextFIELD_NAME and value events that directly
follow field names; null for root level and array values.getCurrentName 在类中 JsonStreamContextpublic final int writeFieldName(String name)
public final int writeValue()
Copyright © 2002–2019 The MyMMSCs Software Foundation. All rights reserved.