Interface ConfigurableConverter<SOURCE,TARGET,OPTION>
- Type Parameters:
SOURCE- the type of the source objectTARGET- the type of the destination objectOPTION- the type of the options list
- All Superinterfaces:
Converter<SOURCE,,TARGET> org.springframework.core.convert.converter.Converter<SOURCE,TARGET>
- All Known Subinterfaces:
ConfigurableSubtypeConverter<SOURCE,TARGET, OPTION>
- All Known Implementing Classes:
DefaultConfigurableConverter,DefaultConfigurableSubtypeAwareConverter,DefaultConfigurableSubtypeConverter
Interface for a configurable converter.
The collection of options is used to control what data is populated.
-
Method Summary
Modifier and TypeMethodDescriptiondefault TARGETConverts the source object, creating a new instance of the destination typedefault TARGETconvert(SOURCE source, Collection<OPTION> options) Converts a SOURCE object into a TARGET object using provided Options.default TARGETConvert the source object by filling the prototypeconvert(SOURCE source, TARGET target, Collection<OPTION> options) Converts a SOURCE object into a TARGET object using provided Options.convertAll(Collection<? extends SOURCE> sources, Collection<OPTION> options) Converts a Collection of SOURCE objects into a List of TARGET objects using provided as Collection Options.convertAll(Collection<? extends SOURCE> sources, OPTION... options) Converts a Collection SOURCE objects into a List of TARGET objects using provided as array Options.Getting default optionsgetTargetInstance(SOURCE source) Getting target instance of source objectMethods inherited from interface de.hybris.platform.servicelayer.dto.converter.Converter
convertAll, convertAllIgnoreExceptions, getLoggerMethods inherited from interface org.springframework.core.convert.converter.Converter
andThen
-
Method Details
-
convert
Description copied from interface:ConverterConverts the source object, creating a new instance of the destination type -
convert
Description copied from interface:ConverterConvert the source object by filling the prototype -
convert
Converts a SOURCE object into a TARGET object using provided Options.- Parameters:
source- - the source objectoptions- - the collection of convert options- Returns:
- the TARGET object
- Throws:
ConversionException- when an error occurs during the conversion process
-
convert
Converts a SOURCE object into a TARGET object using provided Options.- Parameters:
source- - the source objecttarget- - the target objectoptions- - the collection of convert options- Returns:
- the TARGET object
- Throws:
ConversionException- when an error occurs during the conversion process
-
convertAll
Converts a Collection SOURCE objects into a List of TARGET objects using provided as array Options.- Parameters:
sources- - the source objectsoptions- - the array of convert options- Returns:
- the List of TARGET objects
- Throws:
ConversionException- when an error occurs during the conversion process
-
convertAll
Converts a Collection of SOURCE objects into a List of TARGET objects using provided as Collection Options.- Parameters:
sources- - the source objectsoptions- - the array of convert options- Returns:
- the List of TARGET objects
- Throws:
ConversionException- when an error occurs during the conversion process
-
getTargetInstance
Getting target instance of source object- Parameters:
source- - the source object- Returns:
- the TARGET object
-
getDefaultOptions
Collection<OPTION> getDefaultOptions()Getting default options- Returns:
- the Collection of Options
-