java convert date to localdate
date.toInstant().atZone(ZoneId.systemDefault()).toLocaldate()
java convert date to localdate
date.toInstant().atZone(ZoneId.systemDefault()).toLocaldate()
convert date to localdate java
public LocalDate convertToLocalDateViaInstant(Date dateToConvert) {
return dateToConvert.toInstant()
.atZone(ZoneId.systemDefault())
.toLocalDate();
}
convert Date to LocalDate via SQLDate
public LocalDate convertToLocalDateViaSqlDate(Date dateToConvert) {
return new java.sql.Date(dateToConvert.getTime()).toLocalDate();
}
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us