T
- the observed element typeU
- the iterated element typepublic abstract class ObservableToIterableAdapter<T,U> extends java.lang.Object implements CloseableIterable<U>
Modifier and Type | Field and Description |
---|---|
protected rx.Observable<? extends T> |
observable
The observable instance.
|
Constructor and Description |
---|
ObservableToIterableAdapter(rx.Observable<? extends T> observable)
Constructor, saves the source observable.
|
Modifier and Type | Method and Description |
---|---|
CloseableIterator<U> |
iterator() |
protected abstract ObserverToIteratorSink<T,U> |
run(rx.Subscription handle)
The factory method to return an iterator and hand over the close handle
to the original registration to the source.
|
protected final rx.Observable<? extends T> observable
public ObservableToIterableAdapter(rx.Observable<? extends T> observable)
observable
- the source observablepublic CloseableIterator<U> iterator()
iterator
in interface CloseableIterable<U>
iterator
in interface java.lang.Iterable<U>
protected abstract ObserverToIteratorSink<T,U> run(rx.Subscription handle)
handle
- the close handle