public class BufferingResponseListener extends Response.Listener.Empty
Response.Listener.Empty
Constructor and Description |
---|
BufferingResponseListener() |
BufferingResponseListener(int maxLength) |
Modifier and Type | Method and Description |
---|---|
byte[] |
getContent() |
String |
getContent(String encoding) |
void |
onContent(Response response,
ByteBuffer content)
Callback method invoked when the response content has been received.
|
onBegin, onComplete, onFailure, onHeaders, onSuccess
public BufferingResponseListener()
public BufferingResponseListener(int maxLength)
public void onContent(Response response, ByteBuffer content)
Response.Listener
content
buffer must be consumed
before returning from this method.onContent
in interface Response.Listener
onContent
in class Response.Listener.Empty
response
- the response containing the response line data and the headerscontent
- the content bytes receivedpublic byte[] getContent()
Copyright © 1995-2012 Mort Bay Consulting. All Rights Reserved.