Network Response Producer
class NetworkResponseProducer(resourceRetriever: ResourceRetriever, backgroundDispatcher: CoroutineDispatcher) : ResponseProducer
Content copied to clipboard
A ResponseProducer subclass that produces responses from the network
Parameters
resourceRetriever
the ResourceRetriever to use
backgroundDispatcher
the CoroutineDispatcher to use for doing all operations
Constructors
NetworkResponseProducer
Link copied to clipboard
fun NetworkResponseProducer(resourceRetriever: ResourceRetriever, backgroundDispatcher: CoroutineDispatcher = Dispatchers.IO)
Content copied to clipboard
the ResourceRetriever to use
Functions
canHandleRequest
Link copied to clipboard
produceResponse
Link copied to clipboard
open suspend override fun produceResponse(request: Metador.Request): Result<Map<String, String>, Throwable>
Content copied to clipboard