com.caucho.server.cache
Class ProxyCacheResponse

java.lang.Object
  extended by com.caucho.server.http.AbstractCauchoResponse
      extended by com.caucho.server.http.CauchoResponseWrapper
          extended by com.caucho.server.cache.ProxyCacheResponse
All Implemented Interfaces:
CauchoResponse, HttpServletResponse, ServletResponse

public class ProxyCacheResponse
extends CauchoResponseWrapper


Field Summary
 
Fields inherited from interface javax.servlet.http.HttpServletResponse
SC_ACCEPTED, SC_BAD_GATEWAY, SC_BAD_REQUEST, SC_CONFLICT, SC_CONTINUE, SC_CREATED, SC_EXPECTATION_FAILED, SC_FORBIDDEN, SC_FOUND, SC_GATEWAY_TIMEOUT, SC_GONE, SC_HTTP_VERSION_NOT_SUPPORTED, SC_INTERNAL_SERVER_ERROR, SC_LENGTH_REQUIRED, SC_METHOD_NOT_ALLOWED, SC_MOVED_PERMANENTLY, SC_MOVED_TEMPORARILY, SC_MULTIPLE_CHOICES, SC_NO_CONTENT, SC_NON_AUTHORITATIVE_INFORMATION, SC_NOT_ACCEPTABLE, SC_NOT_FOUND, SC_NOT_IMPLEMENTED, SC_NOT_MODIFIED, SC_OK, SC_PARTIAL_CONTENT, SC_PAYMENT_REQUIRED, SC_PRECONDITION_FAILED, SC_PROXY_AUTHENTICATION_REQUIRED, SC_REQUEST_ENTITY_TOO_LARGE, SC_REQUEST_TIMEOUT, SC_REQUEST_URI_TOO_LONG, SC_REQUESTED_RANGE_NOT_SATISFIABLE, SC_RESET_CONTENT, SC_SEE_OTHER, SC_SERVICE_UNAVAILABLE, SC_SWITCHING_PROTOCOLS, SC_TEMPORARY_REDIRECT, SC_UNAUTHORIZED, SC_UNSUPPORTED_MEDIA_TYPE, SC_USE_PROXY
 
Method Summary
 void close()
           
 void flushBuffer()
          Flushes the buffer to the client.
 ServletOutputStream getOutputStream()
          Returns an output stream for writing to the client.
 java.io.PrintWriter getWriter()
          Returns a PrintWriter with the proper character encoding for writing text data to the client.
 void sendError(int code)
          Sends an HTTP error page based on the status code
 void sendError(int code, java.lang.String message)
          Sends an HTTP error page based on the status code
 void setStatus(int code)
          Sets the HTTP status
 void setStatus(int code, java.lang.String message)
           
 void writeHeaders(int length)
           
 
Methods inherited from class com.caucho.server.http.CauchoResponseWrapper
addCookie, addDateHeader, addFooter, addHeader, addIntHeader, completeCache, containsHeader, encodeRedirectUrl, encodeRedirectURL, encodeUrl, encodeURL, getAbstractHttpResponse, getBufferSize, getCauchoResponse, getCharacterEncoding, getContentType, getForbidForward, getHeader, getHeaderNames, getHeaders, getLocale, getRequest, getResponse, getResponseStream, getStatus, getStatusMessage, hasError, isCauchoResponseStream, isCommitted, isForwardEnclosed, isNoCacheUnlessVary, killCache, reset, resetBuffer, sendInternalError, sendRedirect, setBufferSize, setCacheInvocation, setCharacterEncoding, setContentLength, setContentType, setDateHeader, setFooter, setForbidForward, setForwardEnclosed, setHasError, setHeader, setIntHeader, setLocale, setMatchCacheEntry, setNoCache, setPrivateCache, setResponse, setResponseStream, setSessionId, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

setStatus

public void setStatus(int code)
Description copied from interface: HttpServletResponse
Sets the HTTP status

Specified by:
setStatus in interface HttpServletResponse
Overrides:
setStatus in class CauchoResponseWrapper
Parameters:
code - the HTTP status code

setStatus

public void setStatus(int code,
                      java.lang.String message)
Specified by:
setStatus in interface HttpServletResponse
Overrides:
setStatus in class CauchoResponseWrapper

sendError

public void sendError(int code)
               throws java.io.IOException
Description copied from interface: HttpServletResponse
Sends an HTTP error page based on the status code

Specified by:
sendError in interface HttpServletResponse
Overrides:
sendError in class CauchoResponseWrapper
Parameters:
code - the HTTP status code
Throws:
java.io.IOException

sendError

public void sendError(int code,
                      java.lang.String message)
               throws java.io.IOException
Description copied from interface: HttpServletResponse
Sends an HTTP error page based on the status code

Specified by:
sendError in interface HttpServletResponse
Overrides:
sendError in class CauchoResponseWrapper
Parameters:
code - the HTTP status code
Throws:
java.io.IOException

getWriter

public java.io.PrintWriter getWriter()
                              throws java.io.IOException
Description copied from interface: ServletResponse
Returns a PrintWriter with the proper character encoding for writing text data to the client.

Specified by:
getWriter in interface ServletResponse
Overrides:
getWriter in class CauchoResponseWrapper
Throws:
java.io.IOException

getOutputStream

public ServletOutputStream getOutputStream()
                                    throws java.io.IOException
Description copied from interface: ServletResponse
Returns an output stream for writing to the client. You can use the output stream to write binary data.

Specified by:
getOutputStream in interface ServletResponse
Overrides:
getOutputStream in class CauchoResponseWrapper
Throws:
java.io.IOException

flushBuffer

public void flushBuffer()
                 throws java.io.IOException
Description copied from interface: ServletResponse
Flushes the buffer to the client.

Specified by:
flushBuffer in interface ServletResponse
Overrides:
flushBuffer in class CauchoResponseWrapper
Throws:
java.io.IOException

writeHeaders

public void writeHeaders(int length)
                  throws java.io.IOException
Specified by:
writeHeaders in interface CauchoResponse
Overrides:
writeHeaders in class AbstractCauchoResponse
Throws:
java.io.IOException

close

public void close()
           throws java.io.IOException
Specified by:
close in interface CauchoResponse
Overrides:
close in class CauchoResponseWrapper
Throws:
java.io.IOException