public interface Body extends Closeable
| Modifier and Type | Method and Description |
|---|---|
long |
getContentLength()
Gets the length of the body.
|
long |
read(ByteBuffer buffer)
Reads the next chunk of bytes from the body.
|
long getContentLength()
long read(ByteBuffer buffer) throws IOException
buffer - The buffer to store the chunk in, must not be null.-1 if the body has been read completely.IOException - If the chunk could not be read.Copyright © 2022. All Rights Reserved.