@@ -79,6 +79,7 @@ class CompletenessTest extends JUnitSuite {
79
79
" firstOrDefault(T)" -> " firstOrElse(=> U)" ,
80
80
" firstOrDefault(Func1[_ >: T, Boolean], T)" -> " [use `.filter(condition).firstOrElse(default)`]" ,
81
81
" groupBy(Func1[_ >: T, _ <: K], Func1[_ >: T, _ <: R])" -> " [use `groupBy` and `map`]" ,
82
+ " lift(Operator[_ <: R, _ >: T])" -> " lift(Subscriber[R] => Subscriber[_ >: T])" ,
82
83
" mapMany(Func1[_ >: T, _ <: Observable[_ <: R]])" -> " flatMap(T => Observable[R])" ,
83
84
" mapWithIndex(Func2[_ >: T, Integer, _ <: R])" -> " [combine `zipWithIndex` with `map` or with a for comprehension]" ,
84
85
" onErrorResumeNext(Func1[Throwable, _ <: Observable[_ <: T]])" -> " onErrorResumeNext(Throwable => Observable[U])" ,
@@ -89,16 +90,28 @@ class CompletenessTest extends JUnitSuite {
89
90
" parallel(Func1[Observable[T], Observable[R]], Scheduler)" -> " parallel(Observable[T] => Observable[R], Scheduler)" ,
90
91
" reduce(Func2[T, T, T])" -> " reduce((U, U) => U)" ,
91
92
" reduce(R, Func2[R, _ >: T, R])" -> " foldLeft(R)((R, T) => R)" ,
93
+ " retry()" -> " retry()" ,
92
94
" scan(Func2[T, T, T])" -> unnecessary,
93
95
" scan(R, Func2[R, _ >: T, R])" -> " scan(R)((R, T) => R)" ,
94
96
" skip(Int)" -> " drop(Int)" ,
97
+ " skip(Long, TimeUnit)" -> " drop(Duration)" ,
98
+ " skip(Long, TimeUnit, Scheduler)" -> " drop(Duration, Scheduler)" ,
95
99
" skipWhile(Func1[_ >: T, Boolean])" -> " dropWhile(T => Boolean)" ,
96
100
" skipWhileWithIndex(Func2[_ >: T, Integer, Boolean])" -> unnecessary,
97
101
" startWith(Iterable[T])" -> " [unnecessary because we can just use `++` instead]" ,
102
+ " skipLast(Int)" -> " dropRight(Int)" ,
103
+ " skipLast(Long, TimeUnit)" -> " dropRight(Duration)" ,
104
+ " skipLast(Long, TimeUnit, Scheduler)" -> " dropRight(Duration, Scheduler)" ,
98
105
" takeFirst()" -> " first" ,
99
106
" takeFirst(Func1[_ >: T, Boolean])" -> commentForFirstWithPredicate,
100
107
" takeLast(Int)" -> " takeRight(Int)" ,
101
108
" takeWhileWithIndex(Func2[_ >: T, _ >: Integer, Boolean])" -> " [use `.zipWithIndex.takeWhile{case (elem, index) => condition}.map(_._1)`]" ,
109
+ " timeout(Func0[_ <: Observable[U]], Func1[_ >: T, _ <: Observable[V]], Observable[_ <: T])" -> " timeout(() => Observable[U], T => Observable[V], Observable[O])" ,
110
+ " timeout(Func1[_ >: T, _ <: Observable[V]], Observable[_ <: T])" -> " timeout(() => Observable[U], T => Observable[V])" ,
111
+ " timeout(Long, TimeUnit, Observable[_ <: T])" -> " timeout(Duration, Observable[U])" ,
112
+ " timeout(Long, TimeUnit, Observable[_ <: T], Scheduler)" -> " timeout(Duration, Observable[U], Scheduler)" ,
113
+ " timer(Long, Long, TimeUnit)" -> " timer(Duration, Duration)" ,
114
+ " timer(Long, Long, TimeUnit, Scheduler)" -> " timer(Duration, Duration, Scheduler)" ,
102
115
" toList()" -> " toSeq" ,
103
116
" toSortedList()" -> " [Sorting is already done in Scala's collection library, use `.toSeq.map(_.sorted)`]" ,
104
117
" toSortedList(Func2[_ >: T, _ >: T, Integer])" -> " [Sorting is already done in Scala's collection library, use `.toSeq.map(_.sortWith(f))`]" ,
0 commit comments