Class ObjectCodecService
java.lang.Object
org.nuxeo.ecm.automation.io.services.codec.ObjectCodecService
- Author:
- Bogdan Stefanescu
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
static class
static class
static class
static class
static class
-
Field Summary
Modifier and TypeFieldDescriptionprotected Map<Class<?>,
ObjectCodec<?>> protected Map<String,
ObjectCodec<?>> protected Map<Class<?>,
ObjectCodec<?>> protected Map<String,
ObjectCodec<?>> -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addCodec
(ObjectCodec<?> codec) Map<Class<?>,
ObjectCodec<?>> codecs()
Map<String,
ObjectCodec<?>> ObjectCodec<?>
ObjectCodec<?>
Get all codecs.protected void
init()
void
postInit()
read
(com.fasterxml.jackson.core.JsonParser jp, ClassLoader cl, CoreSession session) read
(InputStream in, ClassLoader cl, CoreSession session) read
(InputStream in, CoreSession session) read
(String json, ClassLoader cl, CoreSession session) read
(String json, CoreSession session) protected final Object
readGenericObject
(com.fasterxml.jackson.core.JsonParser jp, String name, ClassLoader cl) readNode
(com.fasterxml.jackson.databind.JsonNode node, ClassLoader cl, CoreSession session) readNode
(com.fasterxml.jackson.databind.JsonNode node, CoreSession session) void
removeCodec
(Class<?> objectType) void
removeCodec
(String name) void
void
write
(OutputStream out, Object object) void
write
(OutputStream out, Object object, boolean prettyPint) protected final void
writeGenericObject
(com.fasterxml.jackson.core.JsonGenerator jg, Class<?> clazz, Object object)
-
Field Details
-
codecs
-
codecsByName
-
_codecs
-
_codecsByName
-
-
Constructor Details
-
ObjectCodecService
public ObjectCodecService(com.fasterxml.jackson.core.JsonFactory jsonFactory)
-
-
Method Details
-
init
protected void init() -
postInit
public void postInit() -
getCodecs
Get all codecs. -
addCodec
-
removeCodec
-
removeCodec
-
getCodec
-
getCodec
-
codecs
-
codecsByName
-
toString
- Throws:
IOException
-
toString
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
write
- Throws:
IOException
-
read
- Throws:
IOException
ClassNotFoundException
-
read
public Object read(String json, ClassLoader cl, CoreSession session) throws IOException, ClassNotFoundException - Throws:
IOException
ClassNotFoundException
-
read
- Throws:
IOException
ClassNotFoundException
-
read
public Object read(InputStream in, ClassLoader cl, CoreSession session) throws IOException, ClassNotFoundException - Throws:
IOException
ClassNotFoundException
-
read
public Object read(com.fasterxml.jackson.core.JsonParser jp, ClassLoader cl, CoreSession session) throws IOException, ClassNotFoundException - Throws:
IOException
ClassNotFoundException
-
readNode
public Object readNode(com.fasterxml.jackson.databind.JsonNode node, ClassLoader cl, CoreSession session) throws IOException - Throws:
IOException
-
readNode
public Object readNode(com.fasterxml.jackson.databind.JsonNode node, CoreSession session) throws IOException - Throws:
IOException
-
writeGenericObject
protected final void writeGenericObject(com.fasterxml.jackson.core.JsonGenerator jg, Class<?> clazz, Object object) throws IOException - Throws:
IOException
-
readGenericObject
protected final Object readGenericObject(com.fasterxml.jackson.core.JsonParser jp, String name, ClassLoader cl) throws IOException - Throws:
IOException
-