Rest Query
fun <T, I, Q> RestQuery(resource: Resource<T, I>, initialId: I, contentType: String, remote: Request, buildQuery: suspend Request.(Q) -> Response)
Content copied to clipboard
Parameters
resource
definition of the Resource
initial Id
id to compare a given resource for differentiation of adding or updating
content Type
to be used by the REST-API
remote
base Request to be used by all subsequent requests. Use it to configure authentication, etc.
build Query
function to build a Request for a given object defining the query