public final class ResponseBytes<ResponseT> extends Object
getObjectBytes
. Can also be retrieved by passing
StreamingResponseHandler.toBytes()
to a streaming output operation.Constructor and Description |
---|
ResponseBytes(ResponseT response,
InputStream responseStream) |
Modifier and Type | Method and Description |
---|---|
byte[] |
asByteArray() |
ByteBuffer |
asByteBuffer() |
String |
asString(Charset charset)
Retrieve the output of the streaming operation as a string.
|
String |
asUtf8String() |
ResponseT |
response() |
public ResponseBytes(ResponseT response, InputStream responseStream) throws IOException
IOException
public ResponseT response()
public ByteBuffer asByteBuffer()
public byte[] asByteArray()
to prevent creating an additional array copy.
public String asString(Charset charset)
charset
- The charset of the string.public String asUtf8String()
Copyright © 2017 Amazon Web Services, Inc. All Rights Reserved.