io.craftsman.creator.LocalDateCreator Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of dozer-jdk8-support Show documentation
Show all versions of dozer-jdk8-support Show documentation
A library that provides the missing Java 8 type mappers for the Dozer Java Bean Mapper.
The newest version!
package io.craftsman.creator;
import java.time.LocalDate;
public class LocalDateCreator implements Creator {
@Override
public LocalDate create(Object source) {
LocalDate srcObject = (LocalDate) source;
return LocalDate.of(srcObject.getYear(), srcObject.getMonth(), srcObject.getDayOfMonth());
}
}