Package org.guvnor.ala.marshalling.impl
Class JSONBaseMarshaller<T>
- java.lang.Object
-
- org.guvnor.ala.marshalling.impl.JSONBaseMarshaller<T>
-
- All Implemented Interfaces:
Marshaller<T>
- Direct Known Subclasses:
PipelineExecutorTraceImplMarshaller
public abstract class JSONBaseMarshaller<T> extends Object implements Marshaller<T>
Base implementation for a JSON marshaller.
-
-
Field Summary
Fields Modifier and Type Field Description protected com.fasterxml.jackson.databind.ObjectMapperobjectMapperprotected Class<T>type
-
Constructor Summary
Constructors Constructor Description JSONBaseMarshaller(Class<T> type)
-
-
-
Method Detail
-
getType
public Class<T> getType()
- Specified by:
getTypein interfaceMarshaller<T>
-
marshal
public String marshal(T value) throws IOException
- Specified by:
marshalin interfaceMarshaller<T>- Throws:
IOException
-
unmarshal
public T unmarshal(String marshalledValue) throws IOException
- Specified by:
unmarshalin interfaceMarshaller<T>- Throws:
IOException
-
-