鍍金池/ 教程/ Android/ TimeInterval
調(diào)度器 Scheduler
Empty/Never/Throw
Replay
這個(gè)頁面展示了創(chuàng)建Observable的各種方法。
ObserveOn
ReactiveX
TimeInterval
Window
本頁展示的操作符用于對整個(gè)序列執(zhí)行算法操作或其它操作,由于這些操作必須等待數(shù)據(jù)發(fā)射完成(通常也必須緩存這些數(shù)據(jù)),它們對于非常長
IgnoreElements
Distinct
Last
Start
And/Then/When
Switch
創(chuàng)建操作
Materialize/Dematerialize
CombineLatest
Catch
實(shí)現(xiàn)自己的操作符
StringObservable
Map
ConnectableObservable
Using
Take
BlockingObservable
TakeLast
Defer
RxJavaSchedulersHook
First
FlatMap
這個(gè)頁面的操作符可用于根據(jù)條件發(fā)射或變換Observables,或者對它們做布爾運(yùn)算:
Do
Repeat
Serialize
這個(gè)頁面展示的操作符可用于過濾和選擇Observable發(fā)射的數(shù)據(jù)序列。
這個(gè)頁面列出了很多用于Observable的輔助操作符
Single
Retry
從錯(cuò)誤中恢復(fù)的技術(shù)
Sample
Merge
算術(shù)和聚合操作
Range
Timestamp
RxJava Issues
From
Subscribe
Subject
Delay
Skip
SubscribeOn
Filter
按字母順序排列的全部操作符列表
Timeout
Scan
onError
Zip
RxJava文檔和教程
Publish
ElementAt
第一個(gè)例子
SkipLast
Just
Timer
Debounce
GroupBy
條件和布爾操作
這個(gè)頁面展示了可用于對Observable發(fā)射的數(shù)據(jù)執(zhí)行變換操作的各種操作符。
Introduction
rxjava-async
介紹響應(yīng)式編程
這個(gè)頁面展示的操作符可用于組合多個(gè)Observables。
ReactiveX
Connect
操作符分類
StartWith
Interval
Join
To
Buffer
RefCount
介紹
Observable

TimeInterval

TimeInterval

將一個(gè)發(fā)射數(shù)據(jù)的Observable轉(zhuǎn)換為發(fā)射那些數(shù)據(jù)發(fā)射時(shí)間間隔的Observable

http://wiki.jikexueyuan.com/project/rx-docs/images/operators/timeInterval.c.png" alt="TimeInterval" />

TimeInterval操作符攔截原始Observable發(fā)射的數(shù)據(jù)項(xiàng),替換為發(fā)射表示相鄰發(fā)射物時(shí)間間隔的對象。

RxJava中的實(shí)現(xiàn)為timeInterval,這個(gè)操作符將原始Observable轉(zhuǎn)換為另一個(gè)Obserervable,后者發(fā)射一個(gè)標(biāo)志替換前者的數(shù)據(jù)項(xiàng),這個(gè)標(biāo)志表示前者的兩個(gè)連續(xù)發(fā)射物之間流逝的時(shí)間長度。新的Observable的第一個(gè)發(fā)射物表示的是在觀察者訂閱原始Observable到原始Observable發(fā)射它的第一項(xiàng)數(shù)據(jù)之間流逝的時(shí)間長度。不存在與原始Observable發(fā)射最后一項(xiàng)數(shù)據(jù)和發(fā)射onCompleted通知之間時(shí)長對應(yīng)的發(fā)射物。

timeInterval默認(rèn)在immediate調(diào)度器上執(zhí)行,你可以通過傳參數(shù)修改。

上一篇:Replay下一篇:Timeout