All Downloads are FREE. Search and download functionalities are using the official Maven repository.

net.intelie.pipes.util.DSTHelper Maven / Gradle / Ivy

There is a newer version: 0.25.5
Show newest version
package net.intelie.pipes.util;

import java.time.LocalDateTime;
import java.time.ZoneId;

public abstract class DSTHelper {
    public static LocalDateTime nextValid(LocalDateTime time, ZoneId zone) {
        LocalDateTime newTime = time.atZone(zone).toLocalDateTime();
        if (!time.equals(newTime))
            return newTime.withMinute(0).withSecond(0).withNano(0);

        return newTime;
    }
}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy