abstract class NodeCursor
extends com.fasterxml.jackson.core.JsonStreamContext
TreeTraversingParser to keep track
of current location within traversed JSON tree.| Modifier and Type | Class and Description |
|---|---|
protected static class |
NodeCursor.ArrayCursor
Cursor used for traversing non-empty JSON Array nodes
|
protected static class |
NodeCursor.ObjectCursor
Cursor used for traversing non-empty JSON Object nodes
|
protected static class |
NodeCursor.RootCursor
Context matching root-level value nodes (i.e.
|
| Modifier and Type | Field and Description |
|---|---|
protected java.lang.String |
_currentName
Current field name
|
protected java.lang.Object |
_currentValue |
protected NodeCursor |
_parent
Parent cursor of this cursor, if any; null for root
cursors.
|
| Constructor and Description |
|---|
NodeCursor(int contextType,
NodeCursor p) |
| Modifier and Type | Method and Description |
|---|---|
abstract boolean |
currentHasChildren() |
abstract JsonNode |
currentNode() |
abstract com.fasterxml.jackson.core.JsonToken |
endToken() |
java.lang.String |
getCurrentName() |
java.lang.Object |
getCurrentValue() |
NodeCursor |
getParent() |
NodeCursor |
iterateChildren()
Method called to create a new context for iterating all
contents of the current structured value (JSON array or object)
|
abstract com.fasterxml.jackson.core.JsonToken |
nextToken() |
abstract com.fasterxml.jackson.core.JsonToken |
nextValue() |
void |
overrideCurrentName(java.lang.String name) |
void |
setCurrentValue(java.lang.Object v) |
protected final NodeCursor _parent
protected java.lang.String _currentName
protected java.lang.Object _currentValue
public NodeCursor(int contextType,
NodeCursor p)
public final NodeCursor getParent()
getParent in class com.fasterxml.jackson.core.JsonStreamContextpublic final java.lang.String getCurrentName()
getCurrentName in class com.fasterxml.jackson.core.JsonStreamContextpublic void overrideCurrentName(java.lang.String name)
public java.lang.Object getCurrentValue()
getCurrentValue in class com.fasterxml.jackson.core.JsonStreamContextpublic void setCurrentValue(java.lang.Object v)
setCurrentValue in class com.fasterxml.jackson.core.JsonStreamContextpublic abstract com.fasterxml.jackson.core.JsonToken nextToken()
public abstract com.fasterxml.jackson.core.JsonToken nextValue()
public abstract com.fasterxml.jackson.core.JsonToken endToken()
public abstract JsonNode currentNode()
public abstract boolean currentHasChildren()
public final NodeCursor iterateChildren()