java.lang.Object
com.github.mizosoft.methanol.internal.cache.RawResponse
com.github.mizosoft.methanol.internal.cache.NetworkResponse
A
RawResponse
that came from the network and may be written to cache.-
Method Summary
Modifier and TypeMethodDescriptionvoid
Discards the response body in background.static NetworkResponse
from
(TrackedResponse<Flow.Publisher<List<ByteBuffer>>> response) <T> CompletableFuture
<TrackedResponse<T>> handleAsync
(HttpResponse.BodyHandler<T> handler, Executor executor) with
(Consumer<ResponseBuilder<?>> mutator) writingWith
(Store.Editor editor, Executor executor, CacheWritingPublisher.Listener writeListener) Methods inherited from class com.github.mizosoft.methanol.internal.cache.RawResponse
get, handle
-
Method Details
-
writingWith
public NetworkResponse writingWith(Store.Editor editor, Executor executor, CacheWritingPublisher.Listener writeListener) throws IOException - Throws:
IOException
-
discard
Discards the response body in background. -
with
- Specified by:
with
in classRawResponse
-
from
-
handleAsync
public <T> CompletableFuture<TrackedResponse<T>> handleAsync(HttpResponse.BodyHandler<T> handler, Executor executor) - Specified by:
handleAsync
in classRawResponse
-