ENTITY - the element type of the entity objectDTO - the generic type of the data transfer objectpublic interface DozerGenericMapper<ENTITY,DTO>
extends de.alpharogroup.bean.mapper.GenericMapper<ENTITY,DTO>
DozerGenericMapper provides the methods for mapping entities to data
transfer objects and back.| Modifier and Type | Method and Description |
|---|---|
Class<DTO> |
getDtoClass()
Gets the data transfer object class.
|
Class<ENTITY> |
getEntityClass()
Gets the entity class.
|
org.dozer.Mapper |
getMapper()
Gets the mapper.
|
default <D,S> List<D> |
map(@NonNull Collection<S> sources,
@NonNull Class<D> destinationClass)
Constructs new instances of destinationClass and performs mapping between from source.
|
default <D,S> D |
map(S source,
@NonNull Class<D> destinationClass)
Constructs new instance of destinationClass and performs mapping between from source.
|
default DTO |
toDto(ENTITY entity) |
default List<DTO> |
toDtos(@NonNull Collection<ENTITY> entities) |
default List<ENTITY> |
toEntities(@NonNull Collection<DTO> dtos) |
default ENTITY |
toEntity(DTO dto) |
Class<DTO> getDtoClass()
org.dozer.Mapper getMapper()
default <D,S> List<D> map(@NonNull @NonNull Collection<S> sources, @NonNull @NonNull Class<D> destinationClass) throws org.dozer.MappingException
map in interface de.alpharogroup.bean.mapper.GenericMapper<ENTITY,DTO>S - the generic type of the sourceD - the generic type of the destinationClasssources - the collection of source objectsdestinationClass - the destination classorg.dozer.MappingException - is thrown if something goes wrong with the mapping process.default <D,S> D map(@NonNull
S source,
@NonNull
@NonNull Class<D> destinationClass)
throws org.dozer.MappingException
map in interface de.alpharogroup.bean.mapper.GenericMapper<ENTITY,DTO>D - the generic type of the destinationClassS - the generic type of the sourcesource - the sourcedestinationClass - the destination classorg.dozer.MappingException - is thrown if something goes wrong with the mapping process.default List<DTO> toDtos(@NonNull @NonNull Collection<ENTITY> entities)
default List<ENTITY> toEntities(@NonNull @NonNull Collection<DTO> dtos)
Copyright © 2015–2020 Alpha Ro Group UG (haftungsbeschrÀngt). All rights reserved.