public class HttpClientReadableByteChannel extends Object implements ReadableByteChannel, AsyncBody.Consumer<List<ByteBuffer>>
ReadableByteChannel
from a HttpResponse
containing an AsyncBody
May be useful eventually to provide a non-blocking channel as well.
Constructor and Description |
---|
HttpClientReadableByteChannel() |
Modifier and Type | Method and Description |
---|---|
void |
close() |
void |
consume(List<ByteBuffer> value,
AsyncBody asyncBody) |
boolean |
isOpen() |
protected void |
onResponse(HttpResponse<AsyncBody> response) |
int |
read(ByteBuffer arg0) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
unwrap
public void consume(List<ByteBuffer> value, AsyncBody asyncBody) throws Exception
consume
in interface AsyncBody.Consumer<List<ByteBuffer>>
Exception
protected void onResponse(HttpResponse<AsyncBody> response)
public void close()
public int read(ByteBuffer arg0) throws IOException
read
in interface ReadableByteChannel
IOException
Copyright © 2015–2024 Red Hat. All rights reserved.