June 2015
Intermediate to advanced
182 pages
3h 56m
English
Aggregate operators produce the Observable instances, which emit only one item and complete. This item is composed or is computed using all the items emitted by the source Observable instance. In this section, we'll talk about only two of them. For more detailed information, refer to https://github.com/ReactiveX/RxJava/wiki/Mathematical-and-Aggregate-Operators.
The first of these operators is the count() or countLong() method. It emits the number of the items emitted by the source Observable instance. For example:
Observable
.range(10, 100)
.count()
.subscribe(System.out::println);This will print 100.
The other one is the toList() or toSortedList() method, which emits a list variable (that ...
Read now
Unlock full access