Class IntervalWindow

    • Constructor Detail

      • IntervalWindow

        public IntervalWindow​(org.joda.time.Instant start,
                              org.joda.time.Instant end)
        Creates a new IntervalWindow that represents the half-open time interval [start, end).
      • IntervalWindow

        public IntervalWindow​(org.joda.time.Instant start,
                              org.joda.time.ReadableDuration size)
    • Method Detail

      • start

        public org.joda.time.Instant start()
        Returns the start of this window, inclusive.
      • end

        public org.joda.time.Instant end()
        Returns the end of this window, exclusive.
      • maxTimestamp

        public org.joda.time.Instant maxTimestamp()
        Returns the largest timestamp that can be included in this window.
        Specified by:
        maxTimestamp in class BoundedWindow
      • contains

        public boolean contains​(IntervalWindow other)
        Returns whether this window contains the given window.
      • isDisjoint

        public boolean isDisjoint​(IntervalWindow other)
        Returns whether this window is disjoint from the given window.
      • intersects

        public boolean intersects​(IntervalWindow other)
        Returns whether this window intersects the given window.
      • span

        public IntervalWindow span​(IntervalWindow other)
        Returns the minimal window that includes both this window and the given window.
      • equals

        public boolean equals​(@Nullable java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object