package com.dayu.general.net
|
|
import com.dayu.baselibrary.net.BaseApiService
|
import io.reactivex.rxjava3.core.Observable
|
import retrofit2.http.Body
|
import retrofit2.http.GET
|
import retrofit2.http.POST
|
import retrofit2.http.Path
|
import retrofit2.http.QueryMap
|
import retrofit2.http.Url
|
|
interface ApiService : BaseApiService {
|
|
@POST
|
fun requestPost(
|
@Url url: String,
|
@Body params: Map<String, @JvmSuppressWildcards Any>
|
): Observable<BaseResponse<Any>>
|
|
@POST
|
fun requestPost(@Url url: String): Observable<BaseResponse<Any>>
|
|
@GET("{url}")
|
fun requestGet(
|
@Path("url") url: String,
|
@QueryMap params: Map<String, @JvmSuppressWildcards Any>
|
): Observable<BaseResponse<Any>>
|
|
@GET("{url}")
|
fun requestGet(@Path("url") url: String): Observable<BaseResponse<Any>>
|
|
}
|