public class StringNavigableJsonAdapter extends NavigableJsonInputAdapter
Constructor and Description |
---|
StringNavigableJsonAdapter(String source,
int initialOffset) |
Modifier and Type | Method and Description |
---|---|
com.fasterxml.jackson.core.JsonParser |
createParser(com.fasterxml.jackson.core.JsonFactory factory)
Creates a parser from given factory
|
boolean |
isAttributeName(JsonPathCursor cursor)
This method verifies that the underlying input currently points
to an attribute name of a Json object.
|
JsonValue |
parseValue(JsonReducedValueParser parser,
int offset)
Tries to parse a single JsonValue from the input.
|
int |
position()
Gives the current position of the cursor.
|
void |
position(int position)
Sets the position of underlying data input.
|
void |
reset()
Resets the read cursor.
|
public StringNavigableJsonAdapter(String source, int initialOffset)
public void position(int position)
NavigableJsonInputAdapter
position
in class NavigableJsonInputAdapter
public int position()
NavigableJsonInputAdapter
position
in class NavigableJsonInputAdapter
public void reset()
NavigableJsonInputAdapter
reset
in class NavigableJsonInputAdapter
public boolean isAttributeName(JsonPathCursor cursor)
NavigableJsonInputAdapter
JsonPathCursor.getCurrent()
method is called to retrieve the attribute name.
The cursor is moved to the end of the attribute name, after
quote character if successful. Otherwise cursor might be in
any position further forward than where it was prior to this
method.isAttributeName
in class NavigableJsonInputAdapter
true
if the given attributeName matches the one
in underlying data inputpublic JsonValue parseValue(JsonReducedValueParser parser, int offset) throws IOException
NavigableJsonInputAdapter
offset
must be pointing to the beginning of a scalar Json value.parseValue
in class NavigableJsonInputAdapter
IOException
- if offset is pointing to a non-scalar
or invalid Json inputpublic com.fasterxml.jackson.core.JsonParser createParser(com.fasterxml.jackson.core.JsonFactory factory) throws IOException
NavigableJsonInputAdapter
createParser
in class NavigableJsonInputAdapter
IOException
Copyright © 2021 Hazelcast, Inc.. All Rights Reserved.