java.lang.Object
io.smallrye.common.search.BinarySearch.LongRange
- Enclosing class:
BinarySearch
Search operations which apply over an
long range.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classSearch operations which apply over anlongrange using a custom midpoint function.static final classSearch operations within a collection. -
Method Summary
Modifier and TypeMethodDescriptionReturns search operations over a space defined by a custom midpoint function.longfind(long from, long to, LongPredicate test) Get the lowest index within the given range that satisfies the given test.Returns search operations over a collection using the current signedness rules for the midpoint function.signed()Returns search operations over a signed-integer space.unsigned()Returns search operations over an unsigned-integer space.
-
Method Details
-
find
Get the lowest index within the given range that satisfies the given test.- Parameters:
from- the low end of the range (inclusive)to- the high end of the range (exclusive)test- the test (must not benull)- Returns:
- the lowest index within the range which satisfies the test, or
toif no values satisfy the test within the range
-
signed
Returns search operations over a signed-integer space.- Returns:
- search operations over a signed-integer space
-
unsigned
Returns search operations over an unsigned-integer space.- Returns:
- search operations over an unsigned-integer space
-
customMidpoint
Returns search operations over a space defined by a custom midpoint function.- Returns:
- search operations over a space defined by a custom midpoint function
-
inCollection
Returns search operations over a collection using the current signedness rules for the midpoint function.- Returns:
- search operations over a collection using the current signedness rules for the midpoint function
-