Module org.eclipse.yasson
Class JsonStructureIterator
java.lang.Object
org.eclipse.yasson.internal.jsonstructure.JsonStructureIterator
- All Implemented Interfaces:
Iterator<jakarta.json.stream.JsonParser.Event>
- Direct Known Subclasses:
JsonArrayIterator
,JsonObjectIterator
abstract class JsonStructureIterator
extends Object
implements Iterator<jakarta.json.stream.JsonParser.Event>
Iterates over
JsonStructure
.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) abstract jakarta.json.bind.JsonbException
Creates an exception for throwing in case of current value type is not compatible with called getter return type.(package private) String
Check the type of currentJsonValue
and return a string representing a value.(package private) abstract jakarta.json.JsonValue
getValue()
Get currentJsonValue
, that the parser is pointing on.(package private) jakarta.json.stream.JsonParser.Event
getValueEvent
(jakarta.json.JsonValue value) ConvertJsonValue
type toJsonParser.Event
.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.Iterator
forEachRemaining, hasNext, next, remove
-
Constructor Details
-
JsonStructureIterator
JsonStructureIterator()
-
-
Method Details
-
getValue
abstract jakarta.json.JsonValue getValue()Get currentJsonValue
, that the parser is pointing on.- Returns:
- JsonValue result.
-
createIncompatibleValueError
abstract jakarta.json.bind.JsonbException createIncompatibleValueError()Creates an exception for throwing in case of current value type is not compatible with called getter return type.- Returns:
- JsonbException with error description.
-
getString
String getString()Check the type of currentJsonValue
and return a string representing a value.- Returns:
- String value for current JsonValue
-
getValueEvent
jakarta.json.stream.JsonParser.Event getValueEvent(jakarta.json.JsonValue value) ConvertJsonValue
type toJsonParser.Event
.- Parameters:
value
- JsonValue- Returns:
- JsonParser event
-