Skip to content

Commit 310d530

Browse files
committed
Update Observable.java
from(scheduler) -> add diagram, standardize javadoc comments range(scheduler) -> add diagram, standardize javadoc comments startWith(scheduler) -> add diagram, standardize javadoc comments
1 parent d1f0258 commit 310d530

File tree

1 file changed

+37
-37
lines changed

1 file changed

+37
-37
lines changed

rxjava-core/src/main/java/rx/Observable.java

Lines changed: 37 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -667,16 +667,16 @@ public static <T> Observable<T> from(Iterable<? extends T> iterable) {
667667

668668
/**
669669
* Converts an {@link Iterable} sequence into an Observable with the specified scheduler.
670-
*
671-
* @param iterable
672-
* the source {@link Iterable} sequence
673-
* @param scheduler
674-
* the scheduler to emit the items of the iterable
675-
* @param <T>
676-
* the type of items in the {@link Iterable} sequence and the type of items to be
677-
* emitted by the resulting Observable
678-
* @return an Observable that emits each item in the source {@link Iterable} sequence with the specified scheduler
679-
* @see <a href="http://msdn.microsoft.com/en-us/library/hh212140(v=vs.103).aspx">MSDN: Observable.ToObservable</a>
670+
* <p>
671+
* <img width="640" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/from.s.png">
672+
*
673+
* @param iterable the source {@link Iterable} sequence
674+
* @param scheduler the scheduler to emit the items of the iterable
675+
* @param <T> the type of items in the {@link Iterable} sequence and the
676+
* type of items to be emitted by the resulting Observable
677+
* @return an Observable that emits each item in the source {@link Iterable}
678+
* sequence with the specified scheduler
679+
* @see <a href="http://msdn.microsoft.com/en-us/library/hh212140.aspx">MSDN: Observable.ToObservable</a>
680680
*/
681681
public static <T> Observable<T> from(Iterable<? extends T> iterable, Scheduler scheduler) {
682682
return from(iterable).observeOn(scheduler);
@@ -977,17 +977,15 @@ public static Observable<Integer> range(int start, int count) {
977977
}
978978

979979
/**
980-
* Generates an Observable that emits a sequence of integers within a specified range with the specified scheduler.
981-
*
982-
* @param start
983-
* the value of the first integer in the sequence
984-
* @param count
985-
* the number of sequential integers to generate
986-
* @param scheduler
987-
* the scheduler to run the generator loop on
980+
* Generates an Observable that emits a sequence of integers within a
981+
* specified range with the specified scheduler.
982+
* <p>
983+
* <img width="640" src="https://github.com/Netflix/RxJava/wiki/images/rx-operators/range.s.png">
984+
* @param start the value of the first integer in the sequence
985+
* @param count the number of sequential integers to generate
986+
* @param scheduler the scheduler to run the generator loop on
988987
* @return an Observable that emits a range of sequential integers
989-
*
990-
* @see <a href="http://msdn.microsoft.com/en-us/library/hh211896(v=vs.103).aspx">Observable.Range Method (Int32, Int32, IScheduler)</a>
988+
* @see <a href="http://msdn.microsoft.com/en-us/library/hh211896.aspx">Observable.Range Method (Int32, Int32, IScheduler)</a>
991989
*/
992990
public static Observable<Integer> range(int start, int count, Scheduler scheduler) {
993991
return range(start, count).observeOn(scheduler);
@@ -3210,7 +3208,7 @@ public Observable<T> filter(Func1<? super T, Boolean> predicate) {
32103208
* <img width="640" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/distinctUntilChanged.png">
32113209
*
32123210
* @return an Observable of sequentially distinct items
3213-
* @see <a href="http://msdn.microsoft.com/en-us/library/hh229494%28v=vs.103%29.aspx">MSDN: Observable.distinctUntilChanged</a>
3211+
* @see <a href="http://msdn.microsoft.com/en-us/library/hh229494.aspx">MSDN: Observable.distinctUntilChanged</a>
32143212
*/
32153213
public Observable<T> distinctUntilChanged() {
32163214
return create(OperationDistinctUntilChanged.distinctUntilChanged(this));
@@ -3227,7 +3225,7 @@ public Observable<T> distinctUntilChanged() {
32273225
* value that is used for deciding whether an item is
32283226
* sequentially distinct from another one or not
32293227
* @return an Observable of sequentially distinct items
3230-
* @see <a href="http://msdn.microsoft.com/en-us/library/hh229508%28v=vs.103%29.aspx">MSDN: Observable.distinctUntilChanged</a>
3228+
* @see <a href="http://msdn.microsoft.com/en-us/library/hh229508.aspx">MSDN: Observable.distinctUntilChanged</a>
32313229
*/
32323230
public <U> Observable<T> distinctUntilChanged(Func1<? super T, ? extends U> keySelector) {
32333231
return create(OperationDistinctUntilChanged.distinctUntilChanged(this, keySelector));
@@ -3240,7 +3238,7 @@ public <U> Observable<T> distinctUntilChanged(Func1<? super T, ? extends U> keyS
32403238
* <img width="640" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/distinct.png">
32413239
*
32423240
* @return an Observable of distinct items
3243-
* @see <a href="http://msdn.microsoft.com/en-us/library/hh229764%28v=vs.103%29.aspx">MSDN: Observable.distinct</a>
3241+
* @see <a href="http://msdn.microsoft.com/en-us/library/hh229764.aspx">MSDN: Observable.distinct</a>
32443242
*/
32453243
public Observable<T> distinct() {
32463244
return create(OperationDistinct.distinct(this));
@@ -3256,7 +3254,7 @@ public Observable<T> distinct() {
32563254
* value that is used to decide whether an item is
32573255
* distinct from another one or not
32583256
* @return an Observable that emits distinct items
3259-
* @see <a href="http://msdn.microsoft.com/en-us/library/hh244310%28v=vs.103%29.aspx">MSDN: Observable.distinct</a>
3257+
* @see <a href="http://msdn.microsoft.com/en-us/library/hh244310.aspx">MSDN: Observable.distinct</a>
32603258
*/
32613259
public <U> Observable<T> distinct(Func1<? super T, ? extends U> keySelector) {
32623260
return create(OperationDistinct.distinct(this, keySelector));
@@ -4588,28 +4586,30 @@ public Observable<T> startWith(Iterable<T> values) {
45884586
}
45894587

45904588
/**
4591-
* Emit a specified set of items with the specified scheduler before beginning to emit items from the source Observable.
4592-
*
4593-
* @param values
4594-
* Iterable of the items you want the modified Observable to emit first
4595-
* @param scheduler
4596-
* The scheduler to emit the prepended values on.
4589+
* Emit a specified set of items with the specified scheduler before
4590+
* beginning to emit items from the source Observable.
4591+
* <p>
4592+
* <img width="640" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/startWith.s.png">
4593+
*
4594+
* @param values iterable of the items you want the modified Observable to emit first
4595+
* @param scheduler the scheduler to emit the prepended values on
45974596
* @return an Observable that exhibits the modified behavior
4598-
* @see <a href="http://msdn.microsoft.com/en-us/library/hh229372(v=vs.103).aspx">MSDN: Observable.StartWith</a>
4597+
* @see <a href="http://msdn.microsoft.com/en-us/library/hh229372.aspx">MSDN: Observable.StartWith</a>
45994598
*/
46004599
public Observable<T> startWith(Iterable<T> values, Scheduler scheduler) {
46014600
return concat(from(values, scheduler), this);
46024601
}
46034602

46044603
/**
4605-
* Emit a specified array of items with the specified scheduler before beginning to emit items from the source Observable.
4604+
* Emit a specified array of items with the specified scheduler before
4605+
* beginning to emit items from the source Observable.
4606+
* <p>
4607+
* <img width="640" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/startWith.s.png">
46064608
*
4607-
* @param values
4608-
* The items you want the modified Observable to emit first
4609-
* @param scheduler
4610-
* The scheduler to emit the prepended values on.
4609+
* @param values the items you want the modified Observable to emit first
4610+
* @param scheduler the scheduler to emit the prepended values on
46114611
* @return an Observable that exhibits the modified behavior
4612-
* @see <a href="http://msdn.microsoft.com/en-us/library/hh229372(v=vs.103).aspx">MSDN: Observable.StartWith</a>
4612+
* @see <a href="http://msdn.microsoft.com/en-us/library/hh229372.aspx">MSDN: Observable.StartWith</a>
46134613
*/
46144614
public Observable<T> startWith(T[] values, Scheduler scheduler) {
46154615
return startWith(Arrays.asList(values), scheduler);

0 commit comments

Comments
 (0)