public class Mapper extends Object
Modifier and Type | Field and Description |
---|---|
protected boolean |
close |
protected ConcurrentMap<Class<?>,Converter<?>> |
converters |
protected static JsonObjectImpl |
EMPTY_OBJECT |
protected javax.json.stream.JsonGeneratorFactory |
generatorFactory |
protected Mappings |
mappings |
protected javax.json.JsonReaderFactory |
readerFactory |
protected int |
version |
Constructor and Description |
---|
Mapper(javax.json.JsonReaderFactory readerFactory,
javax.json.stream.JsonGeneratorFactory generatorFactory,
boolean doClose,
Map<Class<?>,Converter<?>> converters,
int version) |
Modifier and Type | Method and Description |
---|---|
<T> T[] |
readArray(InputStream stream,
Class<T> clazz) |
<T> T[] |
readArray(Reader stream,
Class<T> clazz) |
<C extends Collection<T>,T> |
readCollection(InputStream stream,
ParameterizedType genericType,
Class<T> raw) |
<C extends Collection<T>,T> |
readCollection(Reader stream,
ParameterizedType genericType,
Class<T> raw) |
<T> T |
readObject(InputStream stream,
Type clazz) |
<T> T |
readObject(Reader stream,
Type clazz) |
<T> void |
writeArray(Collection<T> object,
OutputStream stream) |
<T> void |
writeArray(Collection<T> object,
Writer stream) |
<T> void |
writeArray(Object object,
OutputStream stream) |
<T> void |
writeArray(T[] object,
OutputStream stream) |
<T> void |
writeArray(T[] object,
Writer stream) |
<T> void |
writeIterable(Iterable<T> object,
OutputStream stream) |
<T> void |
writeIterable(Iterable<T> object,
Writer stream) |
void |
writeObject(Object object,
OutputStream stream) |
void |
writeObject(Object object,
Writer stream) |
protected static final JsonObjectImpl EMPTY_OBJECT
protected final Mappings mappings
protected final javax.json.JsonReaderFactory readerFactory
protected final javax.json.stream.JsonGeneratorFactory generatorFactory
protected final boolean close
protected final ConcurrentMap<Class<?>,Converter<?>> converters
protected final int version
public <T> void writeArray(Object object, OutputStream stream)
public <T> void writeArray(T[] object, OutputStream stream)
public <T> void writeArray(T[] object, Writer stream)
public <T> void writeArray(Collection<T> object, OutputStream stream)
public <T> void writeArray(Collection<T> object, Writer stream)
public <T> void writeIterable(Iterable<T> object, OutputStream stream)
public void writeObject(Object object, OutputStream stream)
public <T> T readObject(InputStream stream, Type clazz)
public <C extends Collection<T>,T> C readCollection(InputStream stream, ParameterizedType genericType, Class<T> raw)
public <C extends Collection<T>,T> C readCollection(Reader stream, ParameterizedType genericType, Class<T> raw)
public <T> T[] readArray(InputStream stream, Class<T> clazz)
Copyright © 2014 The Apache Software Foundation. All rights reserved.