Book Image

Learning RxJava

By : Nield
Book Image

Learning RxJava

By: Nield

Overview of this book

RxJava is a library for composing asynchronous and event-based programs using Observable sequences for the JVM, allowing developers to build robust applications in less time. Learning RxJava addresses all the fundamentals of reactive programming to help readers write reactive code, as well as teach them an effective approach to designing and implementing reactive libraries and applications. Starting with a brief introduction to reactive programming concepts, there is an overview of Observables and Observers, the core components of RxJava, and how to combine different streams of data and events together. You will also learn simpler ways to achieve concurrency and remain highly performant, with no need for synchronization. Later on, we will leverage backpressure and other strategies to cope with rapidly-producing sources to prevent bottlenecks in your application. After covering custom operators, testing, and debugging, the book dives into hands-on examples using RxJava on Android as well as Kotlin.
Table of Contents (14 chapters)

Future of ReactiveX and Kotlin

Kotlin is a powerful and pragmatic language. JetBrains put in a lot of effort not only to make it effective, but also compatible with existing Java code and libraries. Despite a few rough patches such as SAM lambda inference, they did a phenomenal job making Java and Kotlin work together. However, even with this solid compatibility, many developers become eager to migrate entirely to Kotlin to leverage its functionality. Named parameters, optional parameters, nullable types, extension functions, inline functions, delegates, and other language features make Kotlin attractive for exclusive use. Not to mention, JetBrains has successfully made Kotlin compilable to JavaScript and will soon support LLVM native compilation. Libraries built in pure Kotlin can potentially be compiled to all these platforms. To solidify Kotlin's position even further...