Skip to content

Commit 24e0baf

Browse files
make zip with selector function private because
Scala collections do not have such a function, and we want to be as close to Scala collections as possible
1 parent 4f9105d commit 24e0baf

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

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

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,8 +280,10 @@ trait Observable[+T]
280280
* corresponding elements using the selector function.
281281
* The number of `onNext` invocations of the resulting `Observable[(T, U)]`
282282
* is the minumum of the number of `onNext` invocations of `this` and `that`.
283+
*
284+
* Note that this function is private because Scala collections don't have such a function.
283285
*/
284-
def zip[U, R](that: Observable[U], selector: (T,U) => R): Observable[R] = {
286+
private def zip[U, R](that: Observable[U], selector: (T,U) => R): Observable[R] = {
285287
Observable[R](rx.Observable.zip[T, U, R](this.asJavaObservable, that.asJavaObservable, selector))
286288
}
287289

0 commit comments

Comments
 (0)