(String id, int failcount)
| 7 | |
| 8 | public class StreamExceptions { |
| 9 | static Stream<Breakable> |
| 10 | test(String id, int failcount) { |
| 11 | return |
| 12 | Stream.of(new Breakable(id, failcount)) |
| 13 | .map(Breakable::work) |
| 14 | .map(Breakable::work) |
| 15 | .map(Breakable::work) |
| 16 | .map(Breakable::work); |
| 17 | } |
| 18 | public static void main(String[] args) { |
| 19 | // No operations are even applied ... |
| 20 | test("A", 1); |