()
| 45 | } |
| 46 | |
| 47 | @Setup |
| 48 | public void setup() { |
| 49 | Integer[] array = new Integer[times]; |
| 50 | Arrays.fill(array, 777); |
| 51 | |
| 52 | obsSingle = Observable.fromArray(array).reduce(0, this); |
| 53 | |
| 54 | obsMaybe = Observable.fromArray(array).reduce(this); |
| 55 | |
| 56 | flowSingle = Flowable.fromArray(array).reduce(0, this); |
| 57 | |
| 58 | flowMaybe = Flowable.fromArray(array).reduce(this); |
| 59 | } |
| 60 | |
| 61 | @Benchmark |
| 62 | public void obsSingle(Blackhole bh) { |