Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion Part 3 - Taming the sequence/5. Time-shifted sequences.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ The size of a collection here depends on how many values were emitted in that ti

#### buffer by count and time

You can use both a buffer size and a timespan to buffer values. The buffered values are emitted if either the buffer is full or if the time slot ends and a new one starts. Note that, as of the writting of this guide, the [marble diagram for this operator](https://raw.github.com/wiki/ReactiveX/RxJava/images/rx-operators/buffer6.png) is misleading, as it shows that a timespan resets if a buffer is emitted because it is full.
You can use both a buffer size and a timespan to buffer values. The buffered values are emitted if either the buffer is full or if the time slot ends and a new one starts.

![](https://raw.github.com/wiki/ReactiveX/RxJava/images/rx-operators/buffer6.png)

```java
Observable.interval(100, TimeUnit.MILLISECONDS)
Expand Down