Package com.landawn.abacus.util
Class IntPair
java.lang.Object
com.landawn.abacus.util.IntPair
- All Implemented Interfaces:
Immutable
- Since:
- 1.2
- Author:
- Haiyang Li
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescription<E extends Exception>
voidaccept
(Throwables.IntBiConsumer<E> action) double
average()
boolean
<E extends Exception>
u.Optional<IntPair>filter
(Throwables.IntBiPredicate<E> predicate) <E extends Exception>
voidforEach
(Throwables.IntConsumer<E> comsumer) int
hashCode()
<U,
E extends Exception>
Umap
(Throwables.IntBiFunction<U, E> mapper) int
max()
int
min()
static IntPair
of
(int _1, int _2) reverse()
int
sum()
toString()
-
Field Details
-
_1
public final int _1 -
_2
public final int _2
-
-
Method Details
-
of
- Parameters:
_1
- the 1_2
- the 2- Returns:
-
min
public int min() -
max
public int max() -
sum
public int sum() -
average
public double average() -
reverse
-
forEach
- Type Parameters:
E
-- Parameters:
comsumer
-- Throws:
E
- the e
-
accept
- Type Parameters:
E
-- Parameters:
action
-- Throws:
E
- the e
-
map
- Type Parameters:
U
-E
-- Parameters:
mapper
-- Returns:
- Throws:
E
- the e
-
filter
public <E extends Exception> u.Optional<IntPair> filter(Throwables.IntBiPredicate<E> predicate) throws E - Type Parameters:
E
-- Parameters:
predicate
-- Returns:
- Throws:
E
- the e
-
hashCode
public int hashCode() -
equals
-
toString
-