Skip to content

Commit a590895

Browse files
Merge pull request #1600 from jbripley/rxscala-javadocfixes
RxScala: JavaDoc fixes to not use code or link
2 parents b8e59a8 + 6d6aeaf commit a590895

File tree

1 file changed

+50
-41
lines changed

1 file changed

+50
-41
lines changed

language-adaptors/rxjava-scala/src/main/scala/rx/lang/scala/Observable.scala

Lines changed: 50 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -3178,10 +3178,10 @@ trait Observable[+T]
31783178

31793179
/**
31803180
* Returns an Observable that emits the same values as the source observable with the exception of an
3181-
* {@code onError}. An {@code onError} notification from the source will result in the emission of a
3182-
* {@link Notification} to the Observable provided as an argument to the {@code notificationHandler}
3183-
* function. If the Observable returned {@code onCompletes} or {@code onErrors} then {@code retry} will call
3184-
* {@code onCompleted} or {@code onError} on the child subscription. Otherwise, this Observable will
3181+
* `onError`. An `onError` notification from the source will result in the emission of a
3182+
* [[Notification]] to the Observable provided as an argument to the `notificationHandler`
3183+
* function. If the Observable returned `onCompletes` or `onErrors` then `retry` will call
3184+
* `onCompleted` or `onError` on the child subscription. Otherwise, this Observable will
31853185
* resubscribe to the source Observable.
31863186
* <p>
31873187
* <img width="640" height="430" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/retryWhen.f.png" alt="">
@@ -3190,7 +3190,7 @@ trait Observable[+T]
31903190
*
31913191
* This retries 3 times, each time incrementing the number of seconds it waits.
31923192
*
3193-
* <pre> {@code
3193+
* <pre>
31943194
* Observable[String]({ subscriber =>
31953195
* println("subscribing")
31963196
* subscriber.onError(new RuntimeException("always fails"))
@@ -3200,22 +3200,22 @@ trait Observable[+T]
32003200
* Observable.timer(Duration(i, TimeUnit.SECONDS))
32013201
* })
32023202
* }).toBlocking.foreach(s => println(s))
3203-
* } </pre>
3203+
* </pre>
32043204
*
32053205
* Output is:
32063206
*
3207-
* <pre> {@code
3207+
* <pre>
32083208
* subscribing
32093209
* delay retry by 1 second(s)
32103210
* subscribing
32113211
* delay retry by 2 second(s)
32123212
* subscribing
32133213
* delay retry by 3 second(s)
32143214
* subscribing
3215-
* } </pre>
3215+
* </pre>
32163216
* <dl>
32173217
* <dt><b>Scheduler:</b></dt>
3218-
* <dd>{@code retryWhen} operates by default on the {@code trampoline} {@link Scheduler}.</dd>
3218+
* <dd>`retryWhen` operates by default on the `trampoline` [[Scheduler]].</dd>
32193219
* </dl>
32203220
*
32213221
* @param notificationHandler receives an Observable of notifications with which a user can complete or error, aborting the
@@ -3235,16 +3235,16 @@ trait Observable[+T]
32353235
}
32363236

32373237
/**
3238-
* Returns an Observable that emits the same values as the source observable with the exception of an {@code onError}.
3239-
* An onError will emit a {@link Notification} to the observable provided as an argument to the notificationHandler
3240-
* func. If the observable returned {@code onCompletes} or {@code onErrors} then retry will call {@code onCompleted}
3241-
* or {@code onError} on the child subscription. Otherwise, this observable will resubscribe to the source observable, on a particular Scheduler.
3238+
* Returns an Observable that emits the same values as the source observable with the exception of an `onError`.
3239+
* An onError will emit a [[Notification]] to the observable provided as an argument to the notificationHandler
3240+
* func. If the observable returned `onCompletes` or `onErrors` then retry will call `onCompleted`
3241+
* or `onError` on the child subscription. Otherwise, this observable will resubscribe to the source observable, on a particular Scheduler.
32423242
* <p>
32433243
* <img width="640" height="430" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/retryWhen.f.png" alt="">
32443244
* <p>
32453245
* <dl>
32463246
* <dt><b>Scheduler:</b></dt>
3247-
* <dd>you specify which {@link Scheduler} this operator will use</dd>
3247+
* <dd>you specify which [[Scheduler]] this operator will use</dd>
32483248
* </dl>
32493249
*
32503250
* @param notificationHandler receives an Observable of notifications with which a user can complete or error, aborting the
@@ -3328,16 +3328,16 @@ trait Observable[+T]
33283328

33293329
/**
33303330
* Returns an Observable that emits the same values as the source Observable with the exception of an
3331-
* {@code onCompleted}. An {@code onCompleted} notification from the source will result in the emission of
3332-
* a {@link Notification} to the Observable provided as an argument to the {@code notificationHandler}
3333-
* function. If the Observable returned {@code onCompletes} or {@code onErrors} then {@code repeatWhen} will
3334-
* call {@code onCompleted} or {@code onError} on the child subscription. Otherwise, this Observable will
3331+
* `onCompleted`. An `onCompleted` notification from the source will result in the emission of
3332+
* a [[Notification]] to the Observable provided as an argument to the `notificationHandler`
3333+
* function. If the Observable returned `onCompletes` or `onErrors` then `repeatWhen` will
3334+
* call `onCompleted` or `onError` on the child subscription. Otherwise, this Observable will
33353335
* resubscribe to the source Observable, on a particular Scheduler.
33363336
* <p>
33373337
* <img width="640" height="430" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/repeatWhen.f.png" alt="">
33383338
* <dl>
33393339
* <dt><b>Scheduler:</b></dt>
3340-
* <dd>you specify which {@link Scheduler} this operator will use</dd>
3340+
* <dd>you specify which [[Scheduler]] this operator will use</dd>
33413341
* </dl>
33423342
*
33433343
* @param notificationHandler receives an Observable of notifications with which a user can complete or error, aborting the repeat.
@@ -3359,16 +3359,16 @@ trait Observable[+T]
33593359

33603360
/**
33613361
* Returns an Observable that emits the same values as the source Observable with the exception of an
3362-
* {@code onCompleted}. An {@code onCompleted} notification from the source will result in the emission of
3363-
* a {@link Notification} to the Observable provided as an argument to the {@code notificationHandler}
3364-
* function. If the Observable returned {@code onCompletes} or {@code onErrors} then {@code repeatWhen} will
3365-
* call {@code onCompleted} or {@code onError} on the child subscription. Otherwise, this Observable will
3362+
* `onCompleted`. An `onCompleted` notification from the source will result in the emission of
3363+
* a [[Notification]] to the Observable provided as an argument to the `notificationHandler`
3364+
* function. If the Observable returned `onCompletes` or `onErrors` then `repeatWhen` will
3365+
* call `onCompleted` or `onError` on the child subscription. Otherwise, this Observable will
33663366
* resubscribe to the source observable.
33673367
* <p>
33683368
* <img width="640" height="430" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/repeatWhen.f.png" alt="">
33693369
* <dl>
33703370
* <dt><b>Scheduler:</b></dt>
3371-
* <dd>{@code repeatWhen} operates by default on the {@code trampoline} {@link Scheduler}.</dd>
3371+
* <dd>`repeatWhen` operates by default on the `trampoline` [[Scheduler]].</dd>
33723372
* </dl>
33733373
*
33743374
* @param notificationHandler receives an Observable of notifications with which a user can complete or error, aborting the repeat.
@@ -3787,7 +3787,7 @@ trait Observable[+T]
37873787

37883788
/**
37893789
* Return an Observable that emits a single Map containing values corresponding to items emitted by the
3790-
* source Observable, mapped by the keys returned by a specified {@code keySelector} function.
3790+
* source Observable, mapped by the keys returned by a specified `keySelector` function.
37913791
* <p>
37923792
* <img width="640" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/toMap.png">
37933793
* <p>
@@ -3808,7 +3808,7 @@ trait Observable[+T]
38083808
}
38093809

38103810
/**
3811-
* Return an Observable that emits a single Map, returned by a specified {@code mapFactory} function, that
3811+
* Return an Observable that emits a single Map, returned by a specified `mapFactory` function, that
38123812
* contains keys and values extracted from the items emitted by the source Observable.
38133813
* <p>
38143814
* <img width="640" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/toMap.png">
@@ -3888,18 +3888,27 @@ trait Observable[+T]
38883888
}
38893889

38903890
/**
3891-
* Lift a function to the current Observable and return a new Observable that when subscribed to will pass
3892-
* the values of the current Observable through the function.
3891+
* Lifts a function to the current Observable and returns a new Observable that when subscribed to will pass
3892+
* the values of the current Observable through the Operator function.
38933893
* <p>
38943894
* In other words, this allows chaining Observers together on an Observable for acting on the values within
38953895
* the Observable.
38963896
* {{{
3897-
* observable.map(...).filter(...).take(5).lift(new ObserverA()).lift(new ObserverB(...)).subscribe()
3897+
* observable.map(...).filter(...).take(5).lift(new OperatorA()).lift(new OperatorB(...)).subscribe()
38983898
* }}}
3899+
* If the operator you are creating is designed to act on the individual items emitted by a source
3900+
* Observable, use `lift`. If your operator is designed to transform the source Observable as a whole
3901+
* (for instance, by applying a particular set of existing RxJava operators to it) use `#compose`.
3902+
* <dl>
3903+
* <dt><b>Scheduler:</b></dt>
3904+
* <dd>`lift` does not operate by default on a particular [[Scheduler]].</dd>
3905+
* </dl>
38993906
*
3900-
* @param operator
3901-
* @return an Observable that emits values that are the result of applying the bind function to the values
3902-
* of the current Observable
3907+
* @param operator the Operator that implements the Observable-operating function to be applied to the source
3908+
* Observable
3909+
* @return an Observable that is the result of applying the lifted Operator to the source Observable
3910+
* @see <a href="https://github.com/Netflix/RxJava/wiki/Implementing-Your-Own-Operators">RxJava wiki: Implementing Your Own Operators</a>
3911+
* @since 0.17
39033912
*/
39043913
def lift[R](operator: Subscriber[R] => Subscriber[T]): Observable[R] = {
39053914
toScalaObservable(asJavaObservable.lift(toJavaOperator[T, R](operator)))
@@ -4620,25 +4629,25 @@ object Observable {
46204629
}
46214630

46224631
/**
4623-
* Return an Observable that emits a 0L after the {@code initialDelay} and ever increasing
4624-
* numbers after each {@code period} of time thereafter, on a specified Scheduler.
4632+
* Return an Observable that emits a 0L after the `initialDelay` and ever increasing
4633+
* numbers after each `period` of time thereafter, on a specified Scheduler.
46254634
* <p>
46264635
* <img width="640" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/timer.ps.png">
46274636
*
46284637
* @param initialDelay
46294638
* the initial delay time to wait before emitting the first value of 0L
46304639
* @param period
46314640
* the period of time between emissions of the subsequent numbers
4632-
* @return an Observable that emits a 0L after the { @code initialDelay} and ever increasing
4633-
* numbers after each { @code period} of time thereafter, while running on the given { @code scheduler}
4641+
* @return an Observable that emits a 0L after the `initialDelay` and ever increasing
4642+
* numbers after each `period` of time thereafter, while running on the given `scheduler`
46344643
*/
46354644
def timer(initialDelay: Duration, period: Duration): Observable[Long] = {
46364645
toScalaObservable[java.lang.Long](rx.Observable.timer(initialDelay.toNanos, period.toNanos, duration.NANOSECONDS)).map(_.longValue())
46374646
}
46384647

46394648
/**
4640-
* Return an Observable that emits a 0L after the {@code initialDelay} and ever increasing
4641-
* numbers after each {@code period} of time thereafter, on a specified Scheduler.
4649+
* Return an Observable that emits a 0L after the `initialDelay` and ever increasing
4650+
* numbers after each `period` of time thereafter, on a specified Scheduler.
46424651
* <p>
46434652
* <img width="640" src="https://raw.github.com/wiki/Netflix/RxJava/images/rx-operators/timer.ps.png">
46444653
*
@@ -4647,9 +4656,9 @@ object Observable {
46474656
* @param period
46484657
* the period of time between emissions of the subsequent numbers
46494658
* @param scheduler
4650-
* the scheduler on which the waiting happens and items are emitted
4651-
* @return an Observable that emits a 0L after the { @code initialDelay} and ever increasing
4652-
* numbers after each { @code period} of time thereafter, while running on the given { @code scheduler}
4659+
* the scheduler on which the waiting happens and items are emitted
4660+
* @return an Observable that emits a 0L after the `initialDelay` and ever increasing
4661+
* numbers after each `period` of time thereafter, while running on the given `scheduler`
46534662
*/
46544663
def timer(initialDelay: Duration, period: Duration, scheduler: Scheduler): Observable[Long] = {
46554664
toScalaObservable[java.lang.Long](rx.Observable.timer(initialDelay.toNanos, period.toNanos, duration.NANOSECONDS, scheduler)).map(_.longValue())

0 commit comments

Comments
 (0)