Package generic
Interface ULongSpan
- All Superinterfaces:
Comparable<ULongSpan>
,Span<Long,
ULongSpan>
- All Known Implementing Classes:
ULongSpan.Empty
,ULongSpan.Impl
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic class
An interval tree implementingULongSpan.MutableULongSpanMap
static class
An interval tree implementingULongSpan.MutableULongSpanSet
static enum
The domain of unsigned longsstatic class
The singleton empty span of unsigned longsstatic final record
A non-empty span of unsigned longsstatic interface
A mutable map of unsigned long spans to valuesstatic interface
A mutable set of unsigned long spansstatic interface
A map of unsigned long spans to valuesstatic interface
A set of unsigned long spansNested classes/interfaces inherited from interface generic.Span
Span.DefaultSpanMap<N,
S extends Span<N, S>, V>, Span.DefaultSpanSet<N, S extends Span<N, S>>, Span.MutableSpanMap<N, S extends Span<N, S>, V>, Span.MutableSpanSet<N, S extends Span<N, S>>, Span.SpanMap<N, S extends Span<N, S>, V>, Span.SpanMapSetter<E, N, S extends Span<N, S>, V>, Span.SpanSet<N, S extends Span<N, S>> -
Field Summary
Modifier and TypeFieldDescriptionstatic final ULongSpan.Impl
static final ULongSpan.Domain
static final ULongSpan.Empty
-
Method Summary
Modifier and TypeMethodDescriptionstatic ULongSpan
extent
(long min, int length) Create a closed interval of unsigned longs having the given (unsigned) lengthstatic ULongSpan
extent
(long min, long length) Create a closed interval of unsigned longs having a given lengthdefault long
length()
Get the length of the spanstatic ULongSpan
span
(long min, long max) Create a closed interval of unsigned longsMethods inherited from interface generic.Span
bound, compareTo, contains, domain, doToString, encloses, intersect, intersects, isEmpty, max, maxIsFinite, min, minIsFinite, subtract
-
Field Details
-
DOMAIN
-
EMPTY
-
ALL
-
-
Method Details
-
span
Create a closed interval of unsigned longs- Parameters:
min
- the lower boundmax
- the upper bound- Returns:
- the span
- Throws:
IllegalArgumentException
- ifmax < min
-
extent
Create a closed interval of unsigned longs having a given length- Parameters:
min
- the lower boundlength
- the length- Returns:
- the span
- Throws:
IllegalArgumentException
- if the upper endpoint would exceedULongSpan.Domain.max()
-
extent
Create a closed interval of unsigned longs having the given (unsigned) lengthThis operates the same as
extent(long, int)
, but ensures the given length is treated as an unsigned integer.- Parameters:
min
-length
-- Returns:
- the span
- Throws:
IllegalArgumentException
- if the upper endpoint would exceedULongSpan.Domain.max()
-
length
default long length()Get the length of the span- Returns:
- the length
-