Class MapEntriesArrayDeserializer<K,V>
- java.lang.Object
-
- org.eclipse.yasson.internal.serializer.AbstractItem<java.util.Map<K,V>>
-
- org.eclipse.yasson.internal.serializer.MapEntriesArrayDeserializer<K,V>
-
- Type Parameters:
K-Mapkey type to serializeV-Mapvalue type to serialize
- All Implemented Interfaces:
javax.json.bind.serializer.JsonbDeserializer<java.util.Map<K,V>>,RuntimeTypeInfo,CurrentItem<java.util.Map<K,V>>
public class MapEntriesArrayDeserializer<K,V> extends AbstractItem<java.util.Map<K,V>> implements javax.json.bind.serializer.JsonbDeserializer<java.util.Map<K,V>>
De-serialize JSON array of map entries JSON objects asMap. JSON array of map entries JSON objects:[ { "key": JsonValue, "value": JsonValue }, ... ]
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Map<K,V>deserialize(javax.json.stream.JsonParser parser, javax.json.bind.serializer.DeserializationContext context, java.lang.reflect.Type rtType)De-serialize container stored as JSON structure.voidstartArray(org.eclipse.yasson.internal.serializer.MapEntriesArrayDeserializer.Context ctx, javax.json.stream.JsonParser.Event event)De-serialize JSON structure following beginning of JSON Array ('[').-
Methods inherited from class org.eclipse.yasson.internal.serializer.AbstractItem
getClassModel, getRuntimeType, getWrapper
-
-
-
-
Method Detail
-
deserialize
public java.util.Map<K,V> deserialize(javax.json.stream.JsonParser parser, javax.json.bind.serializer.DeserializationContext context, java.lang.reflect.Type rtType)
De-serialize container stored as JSON structure. Reads JSON tokens from JSON parser and calls corresponding handler method for each of the tokens. Implementing class shall process those tokens and build container instance ofTto be returned.- Specified by:
deserializein interfacejavax.json.bind.serializer.JsonbDeserializer<K>- Parameters:
parser- JSON parsercontext- de-serialization contextrtType- type of returned instance- Returns:
Mapinstance with content of source JSON structure
-
startArray
public void startArray(org.eclipse.yasson.internal.serializer.MapEntriesArrayDeserializer.Context ctx, javax.json.stream.JsonParser.Event event)De-serialize JSON structure following beginning of JSON Array ('[').- Parameters:
ctx- parser contextevent- JSON parser token (event)
-
-