Module com.jongsoft.lang
Package com.jongsoft.lang.time.impl
Class RangeImpl<T extends java.time.temporal.Temporal>
- java.lang.Object
-
- com.jongsoft.lang.time.impl.RangeImpl<T>
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object o)
T
from()
The from part for this temporal range.int
hashCode()
Range<T>
next()
Returns the range exactly after this range.Range<T>
previous()
Returns the range exactly before this range.java.util.stream.Stream<Range<T>>
slice(java.time.temporal.ChronoUnit slicing)
Slice the temporal range into smaller sections, where each slice is at least the indicated ChronoUnit in size.java.lang.String
toString()
T
until()
The until part for this temporal range.
-
-
-
Method Detail
-
from
public T from()
Description copied from interface:Range
The from part for this temporal range.
-
until
public T until()
Description copied from interface:Range
The until part for this temporal range.
-
slice
public java.util.stream.Stream<Range<T>> slice(java.time.temporal.ChronoUnit slicing)
Description copied from interface:Range
Slice the temporal range into smaller sections, where each slice is at least the indicated ChronoUnit in size.
-
previous
public Range<T> previous()
Description copied from interface:Range
Returns the range exactly before this range. If the range was created using a ChronoUnit then the window will shift exactly one ChronoUnit back. If it was created using a from and until it will shift exactly the same size back.
-
next
public Range<T> next()
Description copied from interface:Range
Returns the range exactly after this range. If the range was created using a ChronoUnit then the window will shift exactly one ChronoUnit forward. If it was created using a from and until it will shift exactly the same size forward.
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-