|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.catalina.core.DummyResponse
Dummy response object, used for JSP precompilation.
| 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 |
| Constructor Summary | |
DummyResponse()
|
|
| Method Summary | |
void |
addCookie(javax.servlet.http.Cookie cookie)
|
void |
addDateHeader(java.lang.String name,
long value)
|
void |
addHeader(java.lang.String name,
java.lang.String value)
|
void |
addIntHeader(java.lang.String name,
int value)
|
boolean |
containsHeader(java.lang.String name)
|
javax.servlet.ServletOutputStream |
createOutputStream()
Create and return a ServletOutputStream to write the content associated with this Response. |
java.lang.String |
encodeRedirectUrl(java.lang.String url)
|
java.lang.String |
encodeRedirectURL(java.lang.String url)
|
java.lang.String |
encodeUrl(java.lang.String url)
|
java.lang.String |
encodeURL(java.lang.String url)
|
void |
finishResponse()
Perform whatever actions are required to flush and close the output stream or writer, in a single operation. |
void |
flushBuffer()
|
int |
getBufferSize()
|
java.lang.String |
getCharacterEncoding()
|
Connector |
getConnector()
Return the Connector through which this Response is returned. |
int |
getContentCount()
Return the number of bytes actually written to the output stream. |
int |
getContentLength()
Return the content length that was set or calculated for this Response. |
java.lang.String |
getContentType()
Return the content type that was set or calculated for this response, or null if no content type was set. |
Context |
getContext()
Return the Context with which this Response is associated. |
javax.servlet.http.Cookie[] |
getCookies()
Return an array of all cookies set for this response, or a zero-length array if no cookies have been set. |
java.lang.String |
getHeader(java.lang.String name)
Return the value for the specified header, or null if this
header has not been set. |
java.lang.String[] |
getHeaderNames()
Return an array of all the header names set for this response, or a zero-length array if no headers have been set. |
java.lang.String[] |
getHeaderValues(java.lang.String name)
Return an array of all the header values associated with the specified header name, or an zero-length array if there are no such header values. |
boolean |
getIncluded()
Return the "processing inside an include" flag. |
java.lang.String |
getInfo()
Return descriptive information about this Response implementation and the corresponding version number, in the format <description>/<version>. |
java.util.Locale |
getLocale()
|
java.lang.String |
getMessage()
Return the error message that was set with sendError()
for this Response. |
javax.servlet.ServletOutputStream |
getOutputStream()
|
java.io.PrintWriter |
getReporter()
Return a PrintWriter that can be used to render error messages, regardless of whether a stream or writer has already been acquired. |
Request |
getRequest()
Return the Request with which this Response is associated. |
javax.servlet.ServletResponse |
getResponse()
Return the ServletResponse for which this object
is the facade. |
int |
getStatus()
Return the HTTP status code associated with this Response. |
java.io.OutputStream |
getStream()
Return the output stream associated with this Response. |
java.io.PrintWriter |
getWriter()
|
boolean |
isAppCommitted()
Application commit flag accessor. |
boolean |
isCommitted()
|
boolean |
isError()
Error flag accessor. |
boolean |
isSuspended()
Suspended flag accessor. |
void |
recycle()
Release all object references, and initialize instance variables, in preparation for reuse of this object. |
void |
reset()
|
void |
reset(int status,
java.lang.String message)
Reset this response, and specify the values for the HTTP status code and corresponding message. |
void |
resetBuffer()
Reset the data buffer but not any status or header information. |
void |
sendAcknowledgement()
Send an acknowledgment of a request. |
void |
sendError(int status)
|
void |
sendError(int status,
java.lang.String message)
|
void |
sendRedirect(java.lang.String location)
|
void |
setAppCommitted(boolean appCommitted)
Set the application commit flag. |
void |
setBufferSize(int size)
|
void |
setCharacterEncoding(java.lang.String charEncoding)
|
void |
setConnector(Connector connector)
Set the Connector through which this Response is returned. |
void |
setContentLength(int length)
|
void |
setContentType(java.lang.String type)
|
void |
setContext(Context context)
Set the Context with which this Response is associated. |
void |
setDateHeader(java.lang.String name,
long value)
|
void |
setError()
Set the error flag. |
void |
setHeader(java.lang.String name,
java.lang.String value)
|
void |
setIncluded(boolean included)
Set the "processing inside an include" flag. |
void |
setIntHeader(java.lang.String name,
int value)
|
void |
setLocale(java.util.Locale locale)
|
void |
setRequest(Request request)
Set the Request with which this Response is associated. |
void |
setStatus(int status)
|
void |
setStatus(int status,
java.lang.String message)
|
void |
setStream(java.io.OutputStream stream)
Set the output stream associated with this Response. |
void |
setSuspended(boolean suspended)
Set the suspended flag. |
void |
write(byte[] b)
|
void |
write(byte[] b,
int off,
int len)
|
void |
write(int b)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public DummyResponse()
| Method Detail |
public void setAppCommitted(boolean appCommitted)
Response
setAppCommitted in interface ResponseappCommitted - The new application committed flag valuepublic boolean isAppCommitted()
Response
isAppCommitted in interface Responsepublic Connector getConnector()
Response
getConnector in interface Responsepublic void setConnector(Connector connector)
Response
setConnector in interface Responseconnector - The new connectorpublic int getContentCount()
Response
getContentCount in interface Responsepublic Context getContext()
Response
getContext in interface Responsepublic void setContext(Context context)
Response
setContext in interface Responsecontext - The associated Contextpublic boolean getIncluded()
Response
getIncluded in interface Responsepublic void setIncluded(boolean included)
Response
setIncluded in interface Responseincluded - true if we are currently inside a
RequestDispatcher.include(), else falsepublic java.lang.String getInfo()
Response<description>/<version>.
getInfo in interface Responsepublic Request getRequest()
Response
getRequest in interface Responsepublic void setRequest(Request request)
Response
setRequest in interface Responserequest - The new associated requestpublic javax.servlet.ServletResponse getResponse()
ResponseServletResponse for which this object
is the facade.
getResponse in interface Responsepublic java.io.OutputStream getStream()
Response
getStream in interface Responsepublic void setStream(java.io.OutputStream stream)
Response
setStream in interface Responsestream - The new output streampublic void setSuspended(boolean suspended)
Response
setSuspended in interface Responsesuspended - The new suspended flag valuepublic boolean isSuspended()
Response
isSuspended in interface Responsepublic void setError()
Response
setError in interface Responsepublic boolean isError()
Response
isError in interface Response
public javax.servlet.ServletOutputStream createOutputStream()
throws java.io.IOException
Response
createOutputStream in interface Responsejava.io.IOException - if an input/output error occurs
public void finishResponse()
throws java.io.IOException
Response
finishResponse in interface Responsejava.io.IOException - if an input/output error occurspublic int getContentLength()
Response
getContentLength in interface Responsepublic java.lang.String getContentType()
Responsenull if no content type was set.
getContentType in interface Responsepublic java.io.PrintWriter getReporter()
Response
getReporter in interface Responsepublic void recycle()
Response
recycle in interface Response
public void write(int b)
throws java.io.IOException
java.io.IOException
public void write(byte[] b)
throws java.io.IOException
java.io.IOException
public void write(byte[] b,
int off,
int len)
throws java.io.IOException
java.io.IOException
public void flushBuffer()
throws java.io.IOException
flushBuffer in interface javax.servlet.ServletResponsejava.io.IOExceptionpublic int getBufferSize()
getBufferSize in interface javax.servlet.ServletResponsepublic java.lang.String getCharacterEncoding()
getCharacterEncoding in interface javax.servlet.ServletResponsepublic void setCharacterEncoding(java.lang.String charEncoding)
setCharacterEncoding in interface javax.servlet.ServletResponse
public javax.servlet.ServletOutputStream getOutputStream()
throws java.io.IOException
getOutputStream in interface javax.servlet.ServletResponsejava.io.IOExceptionpublic java.util.Locale getLocale()
getLocale in interface javax.servlet.ServletResponse
public java.io.PrintWriter getWriter()
throws java.io.IOException
getWriter in interface javax.servlet.ServletResponsejava.io.IOExceptionpublic boolean isCommitted()
isCommitted in interface javax.servlet.ServletResponsepublic void reset()
reset in interface javax.servlet.ServletResponsepublic void resetBuffer()
Response
resetBuffer in interface Responsepublic void setBufferSize(int size)
setBufferSize in interface javax.servlet.ServletResponsepublic void setContentLength(int length)
setContentLength in interface javax.servlet.ServletResponsepublic void setContentType(java.lang.String type)
setContentType in interface javax.servlet.ServletResponsepublic void setLocale(java.util.Locale locale)
setLocale in interface javax.servlet.ServletResponsepublic javax.servlet.http.Cookie[] getCookies()
HttpResponse
getCookies in interface HttpResponsepublic java.lang.String getHeader(java.lang.String name)
HttpResponsenull if this
header has not been set. If more than one value was added for this
name, only the first is returned; use getHeaderValues() to retrieve all
of them.
getHeader in interface HttpResponsename - Header name to look uppublic java.lang.String[] getHeaderNames()
HttpResponse
getHeaderNames in interface HttpResponsepublic java.lang.String[] getHeaderValues(java.lang.String name)
HttpResponse
getHeaderValues in interface HttpResponsename - Header name to look uppublic java.lang.String getMessage()
HttpResponsesendError()
for this Response.
getMessage in interface HttpResponsepublic int getStatus()
HttpResponse
getStatus in interface HttpResponse
public void reset(int status,
java.lang.String message)
HttpResponse
reset in interface HttpResponsepublic void addCookie(javax.servlet.http.Cookie cookie)
addCookie in interface javax.servlet.http.HttpServletResponse
public void addDateHeader(java.lang.String name,
long value)
addDateHeader in interface javax.servlet.http.HttpServletResponse
public void addHeader(java.lang.String name,
java.lang.String value)
addHeader in interface javax.servlet.http.HttpServletResponse
public void addIntHeader(java.lang.String name,
int value)
addIntHeader in interface javax.servlet.http.HttpServletResponsepublic boolean containsHeader(java.lang.String name)
containsHeader in interface javax.servlet.http.HttpServletResponsepublic java.lang.String encodeRedirectURL(java.lang.String url)
encodeRedirectURL in interface javax.servlet.http.HttpServletResponsepublic java.lang.String encodeRedirectUrl(java.lang.String url)
encodeRedirectUrl in interface javax.servlet.http.HttpServletResponsepublic java.lang.String encodeURL(java.lang.String url)
encodeURL in interface javax.servlet.http.HttpServletResponsepublic java.lang.String encodeUrl(java.lang.String url)
encodeUrl in interface javax.servlet.http.HttpServletResponse
public void sendAcknowledgement()
throws java.io.IOException
Response
sendAcknowledgement in interface Responsejava.io.IOException - if an input/output error occurs
public void sendError(int status)
throws java.io.IOException
sendError in interface javax.servlet.http.HttpServletResponsejava.io.IOException
public void sendError(int status,
java.lang.String message)
throws java.io.IOException
sendError in interface javax.servlet.http.HttpServletResponsejava.io.IOException
public void sendRedirect(java.lang.String location)
throws java.io.IOException
sendRedirect in interface javax.servlet.http.HttpServletResponsejava.io.IOException
public void setDateHeader(java.lang.String name,
long value)
setDateHeader in interface javax.servlet.http.HttpServletResponse
public void setHeader(java.lang.String name,
java.lang.String value)
setHeader in interface javax.servlet.http.HttpServletResponse
public void setIntHeader(java.lang.String name,
int value)
setIntHeader in interface javax.servlet.http.HttpServletResponsepublic void setStatus(int status)
setStatus in interface javax.servlet.http.HttpServletResponse
public void setStatus(int status,
java.lang.String message)
setStatus in interface javax.servlet.http.HttpServletResponse
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||