Class EveryNWeeksTimeSeries


public class EveryNWeeksTimeSeries extends EveryWeekTimeSeries
  • Constructor Details

    • EveryNWeeksTimeSeries

      public EveryNWeeksTimeSeries(LocalTime instantTime, DayOfWeek dayOfWeek, int nWeeks, Timeable timeable)
  • Method Details

    • nWeeks

      public int nWeeks()
    • getNextInstantTime

      public double getNextInstantTime(double time, boolean timeInclusive)
      Description copied from class: TimeSeries
      Returns the time of the smallest instant of this time series after the specified time, or Double.POSITIVE_INFINITY if there are no such instants in this time series. Allows to include or exclude the specified time itself.
      Overrides:
      getNextInstantTime in class EveryWeekTimeSeries
      Parameters:
      time - specified time
      timeInclusive - whether to include or exclude the specified time
      Returns:
      time of the smallest instant of this time series after the specified time, or Double.POSITIVE_INFINITY
    • getPreviousInstantTime

      public double getPreviousInstantTime(double time)
      Description copied from class: TimeSeries
      Returns the time of the biggest instant of this time series that is strictly less than the the specified time, or Double.NEGATIVE_INFINITY if there is no such instant.
      Overrides:
      getPreviousInstantTime in class EveryWeekTimeSeries
      Parameters:
      time - specified time
      Returns:
      time of the biggest instant of this time series that is strictly less than the the specified time, or Double.NEGATIVE_INFINITY
    • getInstantsTimes

      public List<Double> getInstantsTimes(double beginTime, double endTime, boolean beginTimeInclusive, boolean endTimeInclusive)
      Description copied from class: TimeSeries
      Returns an unmodifiable list containing all times of instants of this time series between the specified times. If there are no such instants, an empty list is returned. Allows to include or exclude the boundaries of the specified time interval.
      Overrides:
      getInstantsTimes in class EveryWeekTimeSeries
      Parameters:
      beginTime - smallest time of instants being returned
      endTime - biggest time of instants being returned
      beginTimeInclusive - whether to include or exclude the right boundary (beginTime)
      endTimeInclusive - whether to include or exclude the left boundary (endTime)
      Returns:
      unmodifiable list containing all times of instants of this time series between the specified times
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class EveryWeekTimeSeries
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class EveryWeekTimeSeries