protected class SegmentedTimeline.SegmentRange extends SegmentedTimeline.Segment
millisecond, segmentEnd, segmentNumber, segmentStart
Constructor and Description |
---|
SegmentRange(long fromMillisecond,
long toMillisecond)
Creates a SegmentRange between a start and end domain values.
|
Modifier and Type | Method and Description |
---|---|
long |
getSegmentCount()
Returns the number of segments contained in this range.
|
void |
inc(long n)
Not implemented for SegmentRange.
|
boolean |
inExcludeSegments()
Returns true if we are an excluded segment.
|
boolean |
inIncludeSegments()
Returns true if all Segments of this SegmentRenge are an included
segment and are not an exception.
|
SegmentedTimeline.Segment |
intersect(long from,
long to)
Returns a segment that is the intersection of this segment and the
interval.
|
after, before, calculateSegmentNumber, compareTo, contained, contains, contains, contains, copy, dec, dec, equals, getDate, getMillisecond, getSegmentEnd, getSegmentNumber, getSegmentStart, inc, inExceptionSegments, moveIndexToEnd, moveIndexToStart
public SegmentRange(long fromMillisecond, long toMillisecond)
fromMillisecond
- start of the rangetoMillisecond
- end of the rangepublic long getSegmentCount()
getSegmentCount
in class SegmentedTimeline.Segment
public SegmentedTimeline.Segment intersect(long from, long to)
intersect
in class SegmentedTimeline.Segment
from
- the start of the interval.to
- the end of the interval.public boolean inIncludeSegments()
inIncludeSegments
in class SegmentedTimeline.Segment
true
or false
.public boolean inExcludeSegments()
inExcludeSegments
in class SegmentedTimeline.Segment
true
or false
.public void inc(long n)
inc
in class SegmentedTimeline.Segment
n
- Number of segments to increment.