Skip to content

Commit 5ac8133

Browse files
authored
🍱 add lambda table
1 parent 7ab5a17 commit 5ac8133

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

java8-lambda/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
|:-----:|:--------|:-------|
66
| `Predicate<T>` | `T->boolean` | `IntPredicate,LongPredicate, DoublePredicate` |
77
| `Consumer<T>` | `T->void` | `IntConsumer,LongConsumer, DoubleConsumer` |
8-
| `Function<T,R>` | `T->R` | `IntFunction<R>, IntToDoubleFunction, IntToLongFunction, LongFunction<R>, LongToDoubleFunction, LongToIntFunction, DoubleFunction<R>, ToIntFunction<T>, ToDoubleFunction<T>, ToLongFunction<T>` |
8+
| `Function<T,R>` | `T->R` | `IntFunction<R>, IntToDoubleFunction,` <br/> `IntToLongFunction, LongFunction<R>,` <br/> `LongToDoubleFunction, LongToIntFunction, ` <br/> `DoubleFunction<R>, ToIntFunction<T>, ` <br/> `ToDoubleFunction<T>, ToLongFunction<T>` |
99
| `Supplier<T>` | `()->T` | `BooleanSupplier,IntSupplier, LongSupplier, DoubleSupplier` |
1010
| `UnaryOperator<T>` | `T->T` | `IntUnaryOperator, LongUnaryOperator, DoubleUnaryOperator` |
1111
| `BinaryOperator<T>` | `(T,T)->T` | `IntBinaryOperator, LongBinaryOperator, DoubleBinaryOperator` |
@@ -22,6 +22,6 @@
2222
| 创建对象 | `() -> new Project()` | `Supplier<Project>` |
2323
| 消费一个对象 | `(Project p) -> System.out.println(p.getStars())` | `Consumer<Project>` |
2424
| 从一个对象中选择/提取 | `(int a, int b) -> a * b` | `IntBinaryOperator` |
25-
| 比较两个对象 | `(Project p1, Project p2) -> p1.getStars().compareTo(p2.getStars())` | `Comparator<Project>或 BiFunction<Project, Project, Integer> 或 ToIntBiFunction<Project, Project>` |
25+
| 比较两个对象 | `(Project p1, Project p2) -> p1.getStars().compareTo(p2.getStars())` | `Comparator<Project> 或 BiFunction<Project, ` <br/> `Project, Integer> 或 ToIntBiFunction<Project, Project>` |
2626

2727

0 commit comments

Comments
 (0)