| Package | Description |
|---|---|
| com.landawn.abacus.util |
| Modifier and Type | Method and Description |
|---|---|
static u.OptionalLong |
Numbers.createLong(String str)
Convert a
String to a Long; since 3.1 it
handles hex (0Xhhhh) and octal (0ddd) notations. |
static u.OptionalLong |
u.OptionalLong.empty() |
<E extends Exception> |
u.OptionalLong.filter(Throwables.LongPredicate<E> predicate) |
<E extends Exception> |
u.OptionalLong.flatMap(Throwables.LongFunction<u.OptionalLong,E> mapper) |
static u.OptionalLong |
u.OptionalLong.from(OptionalLong op) |
static <K> u.OptionalLong |
Maps.getLong(Map<? super K,?> map,
K key)
Returns an empty
OptionalLong if the specified map is empty, or no value found by the specified key, or the value is null. |
<E extends Exception> |
u.OptionalLong.ifPresent(Throwables.LongConsumer<E> action) |
<E extends Exception,E2 extends Exception> |
u.OptionalLong.ifPresentOrElse(Throwables.LongConsumer<E> action,
Throwables.Runnable<E2> emptyAction)
If present or else.
|
<E extends Exception> |
u.OptionalLong.map(Throwables.LongUnaryOperator<E> mapper) |
<E extends Exception> |
u.Optional.mapToLong(Throwables.ToLongFunction<? super T,E> mapper)
Map to long.
|
<E extends Exception> |
u.Nullable.mapToLong(Throwables.ToLongFunction<? super T,E> mapper)
Map to long.
|
<E extends Exception> |
u.OptionalDouble.mapToLong(Throwables.ToLongFunction<Double,E> mapper)
Map to long.
|
<E extends Exception> |
u.OptionalInt.mapToLong(Throwables.ToLongFunction<Integer,E> mapper)
Map to long.
|
<E extends Exception> |
u.Nullable.mapToLongIfNotNull(Throwables.ToLongFunction<? super T,E> mapper)
Map to long if not null.
|
static u.OptionalLong |
Iterables.max(long... a)
Returns
OptionalLong.empty() if the specified Array/Collection is null or empty. |
static u.OptionalLong |
Iterables.min(long... a)
Returns
OptionalLong.empty() if the specified Array/Collection is null or empty. |
static u.OptionalLong |
u.OptionalLong.of(long value) |
static u.OptionalLong |
u.OptionalLong.ofNullable(Long val) |
<E extends Exception> |
u.OptionalLong.or(Throwables.Supplier<u.OptionalLong,E> supplier) |
<E2 extends Exception> |
ExceptionalStream.sumInt(Throwables.ToIntFunction<? super T,E2> func) |
<E2 extends Exception> |
ExceptionalStream.sumLong(Throwables.ToLongFunction<? super T,E2> func) |
| Modifier and Type | Method and Description |
|---|---|
static Pair<Long,u.OptionalLong> |
Median.of(long... a)
Returns a
Pair with left is the value at the index of (a.length - 1) / 2 when the array is sorted,
and the right is the value at the index of a.length / 2 if the length of array is even. |
static Pair<Long,u.OptionalLong> |
Median.of(long[] a,
int fromIndex,
int toIndex)
Returns a
Pair with left is the value at the index of (a.length - 1) / 2 when the array is sorted,
and the right is the value at the index of a.length / 2 if the length of array is even. |
| Modifier and Type | Method and Description |
|---|---|
int |
u.OptionalLong.compareTo(u.OptionalLong optional) |
| Modifier and Type | Method and Description |
|---|---|
<E extends Exception> |
u.OptionalLong.flatMap(Throwables.LongFunction<u.OptionalLong,E> mapper) |
<E extends Exception> |
u.OptionalLong.or(Throwables.Supplier<u.OptionalLong,E> supplier) |
Copyright © 2021. All rights reserved.