RxJava 3 adapter for Retrofit 2


License

License

Categories

Categories

Retrofit Net HTTP Clients RxJava Container Microservices Reactive libraries
GroupId

GroupId

com.github.akarnokd
ArtifactId

ArtifactId

rxjava3-retrofit-adapter
Last Version

Last Version

3.0.0
Release Date

Release Date

Type

Type

jar
Description

Description

RxJava 3 adapter for Retrofit 2
RxJava 3 adapter for Retrofit 2
Project URL

Project URL

https://github.com/akarnokd/RxJavaRetrofitAdapter/
Source Code Management

Source Code Management

https://github.com/akarnokd/RxJavaRetrofitAdapter/

Download rxjava3-retrofit-adapter

How to add to project

<!-- https://jarcasting.com/artifacts/com.github.akarnokd/rxjava3-retrofit-adapter/ -->
<dependency>
    <groupId>com.github.akarnokd</groupId>
    <artifactId>rxjava3-retrofit-adapter</artifactId>
    <version>3.0.0</version>
</dependency>
// https://jarcasting.com/artifacts/com.github.akarnokd/rxjava3-retrofit-adapter/
implementation 'com.github.akarnokd:rxjava3-retrofit-adapter:3.0.0'
// https://jarcasting.com/artifacts/com.github.akarnokd/rxjava3-retrofit-adapter/
implementation ("com.github.akarnokd:rxjava3-retrofit-adapter:3.0.0")
'com.github.akarnokd:rxjava3-retrofit-adapter:jar:3.0.0'
<dependency org="com.github.akarnokd" name="rxjava3-retrofit-adapter" rev="3.0.0">
  <artifact name="rxjava3-retrofit-adapter" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.github.akarnokd', module='rxjava3-retrofit-adapter', version='3.0.0')
)
libraryDependencies += "com.github.akarnokd" % "rxjava3-retrofit-adapter" % "3.0.0"
[com.github.akarnokd/rxjava3-retrofit-adapter "3.0.0"]

Dependencies

runtime (2)

Group / Artifact Type Version
io.reactivex.rxjava3 : rxjava jar 3.0.0
com.squareup.retrofit2 : retrofit jar 2.7.2

test (4)

Group / Artifact Type Version
junit : junit jar 4.13
com.squareup.okhttp3 : mockwebserver jar 4.4.1
org.assertj : assertj-core jar 3.15.0
com.google.guava : guava jar 28.2-jre

Project Modules

There are no modules declared in this project.

RxJavaRetrofitAdapter

RxJava 3 adapter for Retrofit 2

Port of Retrofit/RxJava2 adapter: https://github.com/square/retrofit/tree/master/retrofit-adapters/rxjava2

codecov.io Maven Central

Retrofit 2: Maven Central

RxJava 3: Maven Central

dependencies {
    implementation "com.github.akarnokd:rxjava3-retrofit-adapter:3.0.0"
}

Usage

import retrofit2.*;
import hu.akarnokd.rxjava3.retrofit.*;
import io.reactivex.rxjava3.core.*;

Retrofit retrofit = new Retrofit.Builder()
    .baseUrl("https://example.com/")
    .addCallAdapterFactory(RxJava3CallAdapterFactory.create())
    .build();

interface MyService {
  @GET("/user")
  Observable<User> getUser();
}

Versions

Version
3.0.0
3.0.0-RC8
3.0.0-RC7
3.0.0-RC6
3.0.0-RC5
3.0.0-RC4
3.0.0-RC3
3.0.0-RC2