V - the back end value typeD - the Diffusion value type - must be JSON, String,
Long, Double or Binary types.public interface InboundPayloadConvertor<V,D> extends PayloadConvertor<V,D>
An inbound convertor converts values of external data types to Diffusion data
types. It is used to convert the values passed to a Publisher within
a SourceHandler or HybridHandler via its
publish method.
Inbound Payload convertors are declared with configuration files in the
resource directory META-INF/services. The file name should be
META-INF/services/com.diffusiondata.gateway.framework.convertors.InboundPayloadConvertor
and each line within the file declares the full name of a payload convertor
class.
See Package Guide for
more details.
| Modifier and Type | Field and Description |
|---|---|
static String |
AVRO_TO_JSON
The name of the provided Avro to JSON inbound payload convertor.
|
static String |
CSV_TO_JSON
The name of the provided CSV to JSON inbound payload convertor.
|
DEFAULT_BINARY, DEFAULT_DOUBLE, DEFAULT_INT64, DEFAULT_JSON, DEFAULT_STRING| Modifier and Type | Method and Description |
|---|---|
D |
toDiffusionType(Object value)
Converts a value object of the format known to the back end into a
Diffusion typed object, matching a Diffusion topic type.
|
getDiffusionType, getNamestatic final String AVRO_TO_JSON
see the Package
Guide for full details of the conversions this convertor performs.
static final String CSV_TO_JSON
see the Package
Guide for full details of the conversions this convertor performs.
D toDiffusionType(Object value) throws PayloadConversionException
value - the unconverted valuePayloadConversionException - if the convertor fails to convert the
valueCopyright © 2023 DiffusionData Limited. All rights reserved.