Package org.axonframework.serialization
Interface ContentTypeConverter<S,T>
- Type Parameters:
S- The expected source typeT- The output type
- All Known Implementing Classes:
BlobToInputStreamConverter,ByteArrayToGenericRecordConverter,ByteArrayToInputStreamConverter,ByteArrayToJsonNodeConverter,ByteArrayToJsonNodeConverter,ByteArrayToStringConverter,ChainedConverter,Dom4JToByteArrayConverter,GenericRecordToByteArrayConverter,InputStreamToByteArrayConverter,InputStreamToDom4jConverter,InputStreamToXomConverter,JsonNodeToByteArrayConverter,JsonNodeToByteArrayConverter,JsonNodeToObjectNodeConverter,JsonNodeToObjectNodeConverter,ObjectNodeToJsonNodeConverter,ObjectNodeToJsonNodeConverter,StringToByteArrayConverter,XomToStringConverter
public interface ContentTypeConverter<S,T>
Interface describing a mechanism that converts the data type of IntermediateRepresentations of SerializedObjects for
Upcasters. Different upcasters may require different data type (e.g.
byte[] or
InputStream), or may produce a different data type than they consume.- Since:
- 2.0
- Author:
- Allard Buijze
-
Method Summary
Modifier and TypeMethodDescriptionConverts the given object into another.The expected type of input data.The returned type of IntermediateRepresentation
-
Method Details
-
expectedSourceType
The expected type of input data.- Returns:
- the expected data format in IntermediateRepresentation
-
targetType
The returned type of IntermediateRepresentation- Returns:
- the output data format in IntermediateRepresentation
-
convert
Converts the given object into another. Typically, these values are contained by aSerializedObjectinstance.- Parameters:
original- the value to convert- Returns:
- the converted value
-