Class DJsonContext
java.lang.Object
io.ebeaninternal.server.json.DJsonContext
- All Implemented Interfaces:
io.ebean.text.json.JsonContext, SpiJsonContext
Default implementation of JsonContext.
-
Constructor Summary
ConstructorsConstructorDescriptionDJsonContext(SpiEbeanServer server, com.fasterxml.jackson.core.JsonFactory jsonFactory, TypeManager typeManager) -
Method Summary
Modifier and TypeMethodDescription<T> DJsonBeanReader<T> createBeanReader(io.ebean.plugin.BeanType<T> beanType, com.fasterxml.jackson.core.JsonParser parser, io.ebean.text.json.JsonReadOptions options) <T> DJsonBeanReader<T> createBeanReader(Class<T> cls, com.fasterxml.jackson.core.JsonParser parser, io.ebean.text.json.JsonReadOptions options) com.fasterxml.jackson.core.JsonGeneratorcreateGenerator(Writer writer) createJsonRead(io.ebean.plugin.BeanType<?> beanType, String json) Create a Json Reader for reading the JSON content.createJsonWriter(com.fasterxml.jackson.core.JsonGenerator gen, io.ebean.text.json.JsonWriteOptions options) Create a Json Writer for writing beans as JSON.createJsonWriter(Writer writer) Create a Json Writer for writing beans as JSON supplying a writer.com.fasterxml.jackson.core.JsonParsercreateParser(Reader reader) booleanisSupportedType(Type genericType) <T> T<T> TtoBean(Class<T> cls, com.fasterxml.jackson.core.JsonParser parser, io.ebean.text.json.JsonReadOptions options) <T> T<T> T<T> T<T> T<T> voidtoBean(T target, com.fasterxml.jackson.core.JsonParser parser) <T> voidtoBean(T target, com.fasterxml.jackson.core.JsonParser parser, io.ebean.text.json.JsonReadOptions options) <T> void<T> void<T> void<T> voidvoidvoidtoJson(Object value, com.fasterxml.jackson.core.JsonGenerator generator, io.ebean.FetchPath fetchPath) voidtoJson(Object o, com.fasterxml.jackson.core.JsonGenerator generator, io.ebean.text.json.JsonWriteOptions options) voidvoidvoidtoJsonPretty(Object value) <T> List<T> <T> List<T> toList(Class<T> cls, com.fasterxml.jackson.core.JsonParser src, io.ebean.text.json.JsonReadOptions options) <T> List<T> <T> List<T> <T> List<T> <T> List<T> voidwriteScalar(com.fasterxml.jackson.core.JsonGenerator generator, Object scalarValue)
-
Constructor Details
-
DJsonContext
public DJsonContext(SpiEbeanServer server, com.fasterxml.jackson.core.JsonFactory jsonFactory, TypeManager typeManager)
-
-
Method Details
-
writeScalar
public void writeScalar(com.fasterxml.jackson.core.JsonGenerator generator, Object scalarValue) throws IOException - Specified by:
writeScalarin interfaceio.ebean.text.json.JsonContext- Throws:
IOException
-
isSupportedType
- Specified by:
isSupportedTypein interfaceio.ebean.text.json.JsonContext
-
createGenerator
public com.fasterxml.jackson.core.JsonGenerator createGenerator(Writer writer) throws io.ebean.text.json.JsonIOException - Specified by:
createGeneratorin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
createParser
public com.fasterxml.jackson.core.JsonParser createParser(Reader reader) throws io.ebean.text.json.JsonIOException - Specified by:
createParserin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
toBean
-
toBean
-
toBean
-
toBean
-
toBean
public <T> T toBean(Class<T> cls, com.fasterxml.jackson.core.JsonParser parser) throws io.ebean.text.json.JsonIOException - Specified by:
toBeanin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
toBean
public <T> T toBean(Class<T> cls, com.fasterxml.jackson.core.JsonParser parser, io.ebean.text.json.JsonReadOptions options) throws io.ebean.text.json.JsonIOException - Specified by:
toBeanin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
toBean
- Specified by:
toBeanin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
toBean
public <T> void toBean(T target, String json, io.ebean.text.json.JsonReadOptions options) throws io.ebean.text.json.JsonIOException - Specified by:
toBeanin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
toBean
- Specified by:
toBeanin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
toBean
public <T> void toBean(T target, Reader jsonReader, io.ebean.text.json.JsonReadOptions options) throws io.ebean.text.json.JsonIOException - Specified by:
toBeanin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
toBean
public <T> void toBean(T target, com.fasterxml.jackson.core.JsonParser parser) throws io.ebean.text.json.JsonIOException - Specified by:
toBeanin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
toBean
public <T> void toBean(T target, com.fasterxml.jackson.core.JsonParser parser, io.ebean.text.json.JsonReadOptions options) throws io.ebean.text.json.JsonIOException - Specified by:
toBeanin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
createBeanReader
public <T> DJsonBeanReader<T> createBeanReader(Class<T> cls, com.fasterxml.jackson.core.JsonParser parser, io.ebean.text.json.JsonReadOptions options) throws io.ebean.text.json.JsonIOException - Specified by:
createBeanReaderin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
createBeanReader
public <T> DJsonBeanReader<T> createBeanReader(io.ebean.plugin.BeanType<T> beanType, com.fasterxml.jackson.core.JsonParser parser, io.ebean.text.json.JsonReadOptions options) throws io.ebean.text.json.JsonIOException - Specified by:
createBeanReaderin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
toList
-
toList
-
toList
-
toList
-
toList
-
toList
-
toObject
-
toObject
-
toObject
-
toJson
public void toJson(Object value, com.fasterxml.jackson.core.JsonGenerator generator) throws io.ebean.text.json.JsonIOException - Specified by:
toJsonin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
toJson
public void toJson(Object value, com.fasterxml.jackson.core.JsonGenerator generator, io.ebean.FetchPath fetchPath) throws io.ebean.text.json.JsonIOException - Specified by:
toJsonin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
toJson
public void toJson(Object o, com.fasterxml.jackson.core.JsonGenerator generator, io.ebean.text.json.JsonWriteOptions options) throws io.ebean.text.json.JsonIOException - Specified by:
toJsonin interfaceio.ebean.text.json.JsonContext- Throws:
io.ebean.text.json.JsonIOException
-
toJson
-
toJson
-
toJson
-
toJson
-
toJsonPretty
-
toJson
-
toJson
-
createJsonRead
Description copied from interface:SpiJsonContextCreate a Json Reader for reading the JSON content.- Specified by:
createJsonReadin interfaceSpiJsonContext
-
createJsonWriter
Description copied from interface:SpiJsonContextCreate a Json Writer for writing beans as JSON supplying a writer.- Specified by:
createJsonWriterin interfaceSpiJsonContext
-
createJsonWriter
public SpiJsonWriter createJsonWriter(com.fasterxml.jackson.core.JsonGenerator gen, io.ebean.text.json.JsonWriteOptions options) Description copied from interface:SpiJsonContextCreate a Json Writer for writing beans as JSON.- Specified by:
createJsonWriterin interfaceSpiJsonContext
-