public interface ImmutableSortedListOfRanges extends SortedListOfRanges
SortedListOfRanges specific to immutable implementations. Any methods of
this interface that return a list instance may return references to existing objects.| Modifier and Type | Interface and Description |
|---|---|
static class |
ImmutableSortedListOfRanges.IntersectAndSubtractResult<T extends ImmutableSortedListOfRanges> |
| Modifier and Type | Method and Description |
|---|---|
<T extends SortedListOfRanges> |
create(RangesBuffer buffer)
Returns an immutable equivalent of the given
buffer. |
<T extends SortedListOfRanges> |
createEmpty()
Returns an empty list.
|
<T extends SortedListOfRanges> |
createFull()
|
default <T extends ImmutableSortedListOfRanges> |
createIntersection(T o,
CompilationBuffer compilationBuffer)
Returns the intersection of this list and
o. |
default <T extends ImmutableSortedListOfRanges> |
createIntersection(T o,
RangesBuffer target)
Converts
target to the intersection of this list and o and returns an
immutable equivalent. |
<T extends SortedListOfRanges> |
createInverse()
Returns a list containing all values of [
SortedListOfRanges.getMinValue() SortedListOfRanges.getMaxValue()]
not contained in this list. |
RangesBuffer |
createTempBuffer()
Creates a new buffer that is compatible with this list's storage implementation.
|
boolean |
equalsBuffer(RangesBuffer buffer)
Returns
true if this list equals buffer. |
RangesBuffer |
getBuffer1(CompilationBuffer compilationBuffer)
Returns a buffer from the given
compilationBuffer that is compatible with this list's
storage implementation. |
RangesBuffer |
getBuffer2(CompilationBuffer compilationBuffer)
Returns a buffer from the given
compilationBuffer that is compatible with this list's
storage implementation. |
RangesBuffer |
getBuffer3(CompilationBuffer compilationBuffer)
Returns a buffer from the given
compilationBuffer that is compatible with this list's
storage implementation. |
default <T extends ImmutableSortedListOfRanges> |
intersectAndSubtract(T o,
CompilationBuffer compilationBuffer)
Calculates the intersection and the "rest" of this and
o. |
default <T extends SortedListOfRanges> |
subtract(T o,
CompilationBuffer compilationBuffer)
Returns the result of the subtraction of
o from this list. |
default <T extends ImmutableSortedListOfRanges> |
union(T o)
Returns the union of this list and
o. |
default <T extends ImmutableSortedListOfRanges> |
union(T o,
CompilationBuffer compilationBuffer)
Returns the union of this list and
o. |
default <T extends ImmutableSortedListOfRanges> |
union(T o,
RangesBuffer target)
Converts
target to the union of this list and o and returns an immutable
equivalent. |
addRangeTo, adjacent, adjacent, adjacent, appendRangesTo, binarySearch, binarySearchExactMatch, binarySearchExactMatch, binarySearchGetFirstIntersecting, binarySearchGetFirstIntersecting, binarySearchGetFirstIntersectingOrAdjacent, binarySearchGetFirstIntersectingOrAdjacent, binarySearchNoIntersectingFound, containedBy, contains, contains, contains, contains, contains, defaultToString, equal, equal, equalsListOfRanges, getHi, getLo, getMaxValue, getMinValue, intersects, intersects, intersects, intersects, inverseRangesToString, inverseValueCount, isEmpty, isSingle, leftOf, leftOf, leftOf, leftOf, matches2CharsWith1BitDifference, matchesEverything, matchesNothing, matchesSingleAscii, matchesSingleChar, matchesSomething, rangesAreSortedAndDisjoint, rangesToString, rangeToString, rightOf, rightOf, rightOf, rightOf, size, size, sizeOfInverse, union, valueCount<T extends SortedListOfRanges> T createEmpty()
<T extends SortedListOfRanges> T createFull()
<T extends SortedListOfRanges> T create(RangesBuffer buffer)
buffer.<T extends SortedListOfRanges> T createInverse()
SortedListOfRanges.getMinValue() SortedListOfRanges.getMaxValue()]
not contained in this list.RangesBuffer getBuffer1(CompilationBuffer compilationBuffer)
compilationBuffer that is compatible with this list's
storage implementation.RangesBuffer getBuffer2(CompilationBuffer compilationBuffer)
compilationBuffer that is compatible with this list's
storage implementation.RangesBuffer getBuffer3(CompilationBuffer compilationBuffer)
compilationBuffer that is compatible with this list's
storage implementation.RangesBuffer createTempBuffer()
boolean equalsBuffer(RangesBuffer buffer)
true if this list equals buffer.default <T extends ImmutableSortedListOfRanges> T createIntersection(T o, CompilationBuffer compilationBuffer)
o. Uses
ImmutableSortedListOfRanges.getBuffer1(CompilationBuffer).default <T extends ImmutableSortedListOfRanges> T createIntersection(T o, RangesBuffer target)
target to the intersection of this list and o and returns an
immutable equivalent.default <T extends SortedListOfRanges> T subtract(T o, CompilationBuffer compilationBuffer)
o from this list. Uses
ImmutableSortedListOfRanges.getBuffer1(CompilationBuffer).default <T extends ImmutableSortedListOfRanges> ImmutableSortedListOfRanges.IntersectAndSubtractResult<T> intersectAndSubtract(T o, CompilationBuffer compilationBuffer)
o. Uses
ImmutableSortedListOfRanges.getBuffer1(CompilationBuffer), ImmutableSortedListOfRanges.getBuffer2(CompilationBuffer) and
ImmutableSortedListOfRanges.getBuffer3(CompilationBuffer).o - MatcherBuilder to intersect with.ImmutableSortedListOfRanges.IntersectAndSubtractResult, where field subtractedA is equal to
this.subtract(intersection), subtractedB is equal to
o.subtract(intersection) and intersected is equal to
this.createIntersection(o)default <T extends ImmutableSortedListOfRanges> T union(T o)
o. Creates a temporary buffer.default <T extends ImmutableSortedListOfRanges> T union(T o, CompilationBuffer compilationBuffer)
o. Uses ImmutableSortedListOfRanges.getBuffer1(CompilationBuffer).default <T extends ImmutableSortedListOfRanges> T union(T o, RangesBuffer target)
target to the union of this list and o and returns an immutable
equivalent.