Class CollectionCastConverter<TargetElementType,SourceElementType extends TargetElementType,TargetCollectionType extends java.util.Collection<? extends TargetElementType>,SourceCollectionType extends java.util.Collection<? extends SourceElementType>>
- java.lang.Object
-
- com.saperion.common.lang.conversion.CollectionCastConverter<TargetElementType,SourceElementType,TargetCollectionType,SourceCollectionType>
-
- All Implemented Interfaces:
Converter<SourceCollectionType,TargetCollectionType>
public class CollectionCastConverter<TargetElementType,SourceElementType extends TargetElementType,TargetCollectionType extends java.util.Collection<? extends TargetElementType>,SourceCollectionType extends java.util.Collection<? extends SourceElementType>> extends java.lang.Object implements Converter<SourceCollectionType,TargetCollectionType>
Converts from SourceCollectionType to TargetCollectionType by using a cast.- Author:
- jschwarz
-
-
Constructor Summary
Constructors Constructor Description CollectionCastConverter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description TargetCollectionType
convert(SourceCollectionType object)
Converts the specified object and returns the conversion result.
-
-
-
Method Detail
-
convert
public TargetCollectionType convert(SourceCollectionType object)
Description copied from interface:Converter
Converts the specified object and returns the conversion result. Implementations have to acceptnull
-values without throwing exceptions.- Specified by:
convert
in interfaceConverter<TargetElementType,SourceElementType extends TargetElementType>
- Parameters:
object
- object to convert- Returns:
- the converted object
-
-