函数式接口
2021-04-06 17:30:02 0 举报
AI智能生成
java8函数式接口与方法说明汇总
作者其他创作
大纲/内容
函数式接口
Predicate
Predicate<T>
boolean test(T t)
Predicate<T> and(Predicate<? super T> other)
Predicate<T> negate()
Predicate<T> or(Predicate<? super T> other)
static <T> Predicate<T> isEqual(Object targetRef)
XXXPredicate
IntPredicate
boolean test(int value)
IntPredicate and(IntPredicate other)
IntPredicate negate()
IntPredicate or(IntPredicate other)
LongPredicate
boolean test(long value)
LongPredicate and(LongPredicate other)
LongPredicate negate()
LongPredicate or(LongPredicate other)
DoublePredicate
boolean test(double value)
DoublePredicate and(DoublePredicate other)
DoublePredicate negate()
DoublePredicate or(DoublePredicate other)
BiPredicate
Function
R apply(T t)
XXXToFunction
IntFunction<R>
R apply(int value)
DoubleFunction<R>
R apply(double value)
LongFunction<R>
R apply(long value)
ToXXXFunction<T>
ToIntFunction<T>
int applyAsInt(T value)
ToLongFunction<T>
long applyAsLong(T value)
ToDoubleFunction<T>
double applyAsDouble(T value)
XXXToXXXFunction
IntToXXXFunction
IntToDoubleFunction
double applyAsDouble(int value)
IntToLongFunction
long applyAsLong(int value)
LongToXXXFunction
LongToDoubleFunction
double applyAsDouble(long value)
LongToIntFunction
int applyAsInt(long value)
DoubleToXXXFunction
DoubleToIntFunction
int applyAsInt(double value)
DoubleToLongFunction
long applyAsLong(double value)
BiFunction
Supplier
Supplier<T>
T get()
XXXSupplier
BooleanSupplier
boolean getAsBoolean()
IntSupplier
int getAsInt()
LongSupplier
long getAsLong()
DoubleSupplier
double getAsDouble()
Consumer
Consumer<T>
void accept(T t)
Consumer andThen(Consumer<? super T> after)
XXXConsumer
IntConsumer
void accept(int value)
IntConsumer andThen(IntConsumer after)
LongConsumer
void accept(long value)
LongConsumer andThen(LongConsumer after)
DoubleConsumer
void accept(double value)
DoubleConsumer andThen(DoubleConsumer after)
ObjXXXConsumer
ObjIntConsumer<T>
ObjLongConsumer<T>
ObjDoubleConsumer<T>
\tBiConsumer
Operator
UnaryOperator
UnaryOperator<T>
static <T> UnaryOperator<T> identity()
extends Function <T,T>
XXXUnaryOperator
IntUnaryOperator
int applyAsInt(int operand)
IntUnaryOperator compose(IntUnaryOperator before)
IntUnaryOperator andThen(IntUnaryOperator after)
static IntUnaryOperator identity()
LongUnaryOperator
long applyAsLong(long operand)
LongUnaryOperator compose(LongUnaryOperator before)
LongUnaryOperator andThen(LongUnaryOperator after)
static LongUnaryOperator identity()
DoubleUnaryOperator
double applyAsDouble(double operand)
DoubleUnaryOperator compose(DoubleUnaryOperator before)
DoubleUnaryOperator andThen(DoubleUnaryOperator after)
static DoubleUnaryOperator identity()
BinaryOperator
BinaryOperator<T>
static <T> BinaryOperator<T> minBy(Comparator<? super T> comparator)
static <T> BinaryOperator<T> maxBy(Comparator<? super T> comparator)
extends BiFunction <T,T,T>
XXXBinaryOperator
IntBinaryOperator
LongBinaryOperator
DoubleBinaryOperator
0 条评论
回复 删除
下一页