|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.fasterxml.jackson.core.JsonStreamContext com.fasterxml.jackson.core.json.JsonWriteContext
public class JsonWriteContext
Extension of JsonStreamContext
, which implements
core methods needed, and also exposes
more complete API to generator implementation classes.
Field Summary | |
---|---|
protected JsonWriteContext |
_child
|
protected String |
_currentName
Name of the field of which value is to be parsed; only used for OBJECT contexts |
protected JsonWriteContext |
_parent
|
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
|
Fields inherited from class com.fasterxml.jackson.core.JsonStreamContext |
---|
_index, _type, TYPE_ARRAY, TYPE_OBJECT, TYPE_ROOT |
Constructor Summary | |
---|---|
protected |
JsonWriteContext(int type,
JsonWriteContext parent)
|
Method Summary | |
---|---|
protected void |
appendDesc(StringBuilder sb)
|
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()
|
Methods inherited from class com.fasterxml.jackson.core.JsonStreamContext |
---|
getCurrentIndex, getEntryCount, getTypeDesc, inArray, inObject, inRoot |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public 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
protected final JsonWriteContext _parent
protected String _currentName
protected JsonWriteContext _child
Constructor Detail |
---|
protected JsonWriteContext(int type, JsonWriteContext parent)
Method Detail |
---|
public static JsonWriteContext createRootContext()
public final JsonWriteContext createChildArrayContext()
public final JsonWriteContext createChildObjectContext()
public final JsonWriteContext getParent()
JsonStreamContext
getParent
in class JsonStreamContext
public final String getCurrentName()
JsonStreamContext
FIELD_NAME
and value events that directly
follow field names; null for root level and array values.
getCurrentName
in class JsonStreamContext
public final int writeFieldName(String name)
public final int writeValue()
protected final void appendDesc(StringBuilder sb)
public final String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |