org.apache.wicket.response
Class ByteArrayResponse

java.lang.Object
  extended by org.apache.wicket.request.Response
      extended by org.apache.wicket.response.ByteArrayResponse

public class ByteArrayResponse
extends Response

Response used to capture output as a byte array

Author:
igor.vaynberg

Constructor Summary
ByteArrayResponse()
          Constructor
ByteArrayResponse(Response original)
          Constructor
 
Method Summary
 String encodeURL(CharSequence url)
          Encodes the specified URL by including the session ID in it, or, if encoding is not needed, returns the URL unchanged.
 byte[] getBytes()
           
 void reset()
          Called when the Response needs to reset itself.
 void write(byte[] array)
          Writes the buffer to output.
 void write(CharSequence string)
          Writes the CharSequence to output.
 
Methods inherited from class org.apache.wicket.request.Response
close
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ByteArrayResponse

public ByteArrayResponse(Response original)
Constructor

Parameters:
original -

ByteArrayResponse

public ByteArrayResponse()
Constructor

Method Detail

getBytes

public byte[] getBytes()

write

public void write(CharSequence string)
Description copied from class: Response
Writes the CharSequence to output.

Specified by:
write in class Response
See Also:
Response.write(CharSequence)

reset

public void reset()
Description copied from class: Response
Called when the Response needs to reset itself. Subclasses can empty there buffer or build up state.

Overrides:
reset in class Response
See Also:
Response.reset()

write

public void write(byte[] array)
Description copied from class: Response
Writes the buffer to output.

Specified by:
write in class Response
See Also:
org.apache.wicket.request.Response#getOutputStream()

encodeURL

public String encodeURL(CharSequence url)
Description copied from class: Response
Encodes the specified URL by including the session ID in it, or, if encoding is not needed, returns the URL unchanged.

Specified by:
encodeURL in class Response
Returns:
encoded URL


Copyright © 2004-2010 Apache Software Foundation. All Rights Reserved.