public class UpdaterMapper<T> extends JsonReaderI<T>
base
Constructor and Description |
---|
UpdaterMapper(JsonReader base,
T obj) |
UpdaterMapper(JsonReader base,
T obj,
Type type) |
Modifier and Type | Method and Description |
---|---|
void |
addValue(Object current,
Object value)
add a value in an array json object.
|
T |
convert(Object current)
Allow a mapper to converte a temprary structure to the final data format.
|
Object |
createArray()
use to instantiate a new object that will be used as an array
|
Object |
createObject()
use to instantiate a new object that will be used as an object
|
void |
setValue(Object current,
String key,
Object value)
called when json-smart done parsing a value
|
JsonReaderI<?> |
startArray(String key)
called when json-smart parser start an array.
|
JsonReaderI<?> |
startObject(String key)
called when json-smart parser meet an object key
|
getType, getValue
public UpdaterMapper(JsonReader base, T obj)
public UpdaterMapper(JsonReader base, T obj, Type type)
public JsonReaderI<?> startObject(String key) throws ParseException, IOException
startObject
in class JsonReaderI<T>
ParseException
IOException
public JsonReaderI<?> startArray(String key) throws ParseException, IOException
startArray
in class JsonReaderI<T>
key
- the destination key name, or null.ParseException
IOException
public void setValue(Object current, String key, Object value) throws ParseException, IOException
setValue
in class JsonReaderI<T>
ParseException
IOException
public void addValue(Object current, Object value) throws ParseException, IOException
addValue
in class JsonReaderI<T>
ParseException
IOException
public Object createObject()
createObject
in class JsonReaderI<T>
public Object createArray()
createArray
in class JsonReaderI<T>
public T convert(Object current)
convert
in class JsonReaderI<T>
Copyright © 2017 Chemouni Uriel. All rights reserved.