Skip to content

Latest commit

 

History

History
executable file
·
50 lines (37 loc) · 1.18 KB

README.md

File metadata and controls

executable file
·
50 lines (37 loc) · 1.18 KB

Kotlin Adaptor for RxJava

This adaptor exposes a set of Extension functions that allow a more idiomatic Kotlin usage

    observable<String> { subscriber ->
        subscriber.onNext("H")
        subscriber.onNext("e")
        subscriber.onNext("l")
        subscriber.onNext("")
        subscriber.onNext("l")
        subscriber.onNext("o")
        subscriber.onCompleted()
    }.filter { it.isNotEmpty() }
    .fold (StringBuilder()) { sb, e -> sb.append(e) }
    .map { it.toString() }
    .subscribe { a.received(it) }

    verify(a, times(1)).received("Hello")

Build

Build Status

Binaries

Binaries and dependency information for Maven, Ivy, Gradle and others can be found at http://search.maven.org.

Example for Maven:

<dependency>
    <groupId>io.reactivex</groupId>
    <artifactId>rxkotlin</artifactId>
    <version>x.y.z</version>
</dependency>

and for Ivy:

<dependency org="io.reactivex" name="rxkotlin" rev="x.y.z" />

and for Gradle:

compile 'io.reactivex:rxkotlin:x.y.z'