Created
November 4, 2018 09:31
-
-
Save imrankst1221/67a92073b2d804ba399a185c9debc404 to your computer and use it in GitHub Desktop.
Retrofit Client Builder
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
object ApiService { | |
private val TAG = "--ApiService" | |
fun loginApiCall() = Retrofit.Builder() | |
.baseUrl(Constants.API_BASE_PATH) | |
.addCallAdapterFactory(RxJava2CallAdapterFactory.create()) | |
.addConverterFactory(ApiWorker.gsonConverter) | |
.client(ApiWorker.client) | |
.build() | |
.create(LoginApiService::class.java)!! | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment