Interface DataStructureConverter<I,E>
- Type Parameters:
I- internal data structure (seeRowData)E- external data structure (seeDataType.getConversionClass())
- All Superinterfaces:
Serializable
- All Known Implementing Classes:
ArrayBooleanArrayConverter,ArrayByteArrayConverter,ArrayDoubleArrayConverter,ArrayFloatArrayConverter,ArrayIntArrayConverter,ArrayListConverter,ArrayLongArrayConverter,ArrayObjectArrayConverter,ArrayShortArrayConverter,DateDateConverter,DateLocalDateConverter,DayTimeIntervalDurationConverter,DecimalBigDecimalConverter,IdentityConverter,LocalZonedTimestampInstantConverter,LocalZonedTimestampIntConverter,LocalZonedTimestampLongConverter,LocalZonedTimestampTimestampConverter,MapMapConverter,RawByteArrayConverter,RawObjectConverter,RowRowConverter,StringByteArrayConverter,StringStringConverter,StructuredObjectConverter,TimeLocalTimeConverter,TimeLongConverter,TimestampLocalDateTimeConverter,TimestampTimestampConverter,TimeTimeConverter,YearMonthIntervalPeriodConverter
Converter between internal and external data structure.
Converters are serializable and can be passed to runtime operators. However, converters are not thread-safe.
-
Method Summary
Modifier and TypeMethodDescriptiondefault booleanReturns whether this conversion is a no-op.default voidopen(ClassLoader classLoader) toExternal(I internal) Converts to external data structure.default EtoExternalOrNull(I internal) Converts to external data structure ornull.toInternal(E external) Converts to internal data structure.default ItoInternalOrNull(E external) Converts to internal data structure ornull.
-
Method Details
-
open
-
toInternal
Converts to internal data structure.Note: Parameter must not be null. Output must not be null.
-
toInternalOrNull
Converts to internal data structure ornull.The nullability could be derived from the data type. However, this method reduces null checks.
-
toExternal
Converts to external data structure.Note: Parameter must not be null. Output must not be null.
-
toExternalOrNull
Converts to external data structure ornull.The nullability could be derived from the data type. However, this method reduces null checks.
-
isIdentityConversion
default boolean isIdentityConversion()Returns whether this conversion is a no-op.An identity conversion means that the type is already an internal data structure.
-