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

com.nls.util.DateTimeRangeSet Maven / Gradle / Ivy

There is a newer version: 1.0.14
Show newest version
package com.nls.util;

import org.joda.time.DateTime;
import org.joda.time.Seconds;

public class DateTimeRangeSet extends RangeSet {
    public DateTimeRangeSet() {
    }

    public Seconds getSeconds() {
        Seconds total = Seconds.seconds(0);
        for (Range range : getRanges()) {
            total = total.plus(Seconds.secondsBetween(range.getFrom(), range.getTo()));
        }
        return total;
    }

    protected RangeSet make() {
        return new DateTimeRangeSet();
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy