类 DozerUtil
java.lang.Object
vip.mate.core.dozer.util.DozerUtil
public class DozerUtil extends Object
Dozer工具类
- 作者:
- pangu
-
字段概要
字段 修饰符和类型 字段 说明 private com.github.dozermapper.core.Mappermapper -
构造器概要
构造器 构造器 说明 DozerUtil(com.github.dozermapper.core.Mapper mapper) -
方法概要
修饰符和类型 方法 说明 com.github.dozermapper.core.MappergetMapper()<T> Tmap(Object source, Class<T> destinationClass)Constructs new instance of destinationClass and performs mapping between from source<T> Tmap(Object source, Class<T> destinationClass, String mapId)Constructs new instance of destinationClass and performs mapping between from sourcevoidmap(Object source, Object destination)Performs mapping between source and destination objectsvoidmap(Object source, Object destination, String mapId)Performs mapping between source and destination objects<T> Tmap2(Object source, Class<T> destinationClass)<T, E> List<T>mapList(Collection<E> sourceList, Class<T> destinationClass)将集合转成集合 List --> List<T, E> List<T>mapPage(Collection<E> sourceList, Class<T> destinationClass)<T, E> Set<T>mapSet(Collection<E> sourceList, Class<T> destinationClass)
-
字段详细资料
-
mapper
private com.github.dozermapper.core.Mapper mapper
-
-
构造器详细资料
-
DozerUtil
public DozerUtil(com.github.dozermapper.core.Mapper mapper)
-
-
方法详细资料
-
getMapper
public com.github.dozermapper.core.Mapper getMapper() -
map
Constructs new instance of destinationClass and performs mapping between from source- 类型参数:
T-- 参数:
source-destinationClass-- 返回:
-
map2
-
map
Performs mapping between source and destination objects- 参数:
source-destination-
-
map
Constructs new instance of destinationClass and performs mapping between from source- 类型参数:
T-- 参数:
source-destinationClass-mapId-- 返回:
-
map
Performs mapping between source and destination objects- 参数:
source-destination-mapId-
-
mapList
将集合转成集合 List --> List- 类型参数:
T-- 参数:
sourceList- 源集合destinationClass- 待转类型- 返回:
-
mapPage
-
mapSet
-