Package com.ning.http.client.consumers
Class AppendableBodyConsumer
java.lang.Object
com.ning.http.client.consumers.AppendableBodyConsumer
- All Implemented Interfaces:
BodyConsumer,Closeable,AutoCloseable
An
Appendable customer for ByteBuffer-
Constructor Summary
ConstructorsConstructorDescriptionAppendableBodyConsumer(Appendable appendable) AppendableBodyConsumer(Appendable appendable, String encoding) -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()voidconsume(ByteBuffer byteBuffer) Consume the received bytes.
-
Constructor Details
-
AppendableBodyConsumer
-
AppendableBodyConsumer
-
-
Method Details
-
consume
Description copied from interface:BodyConsumerConsume the received bytes.- Specified by:
consumein interfaceBodyConsumer- Parameters:
byteBuffer- aByteBufferrepresntation of the response's chunk.- Throws:
IOException
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-