Response (Catalina Internal API Documentation)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A Response is the Catalina-internal facade for a
ServletResponse
that is to be produced,
based on the processing of a corresponding Request
.
Method Summary | |
javax.servlet.ServletOutputStream |
createOutputStream()
Create and return a ServletOutputStream to write the content associated with this Response. |
void |
finishResponse()
Perform whatever actions are required to flush and close the output stream or writer, in a single operation. |
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. |
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.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. |
java.io.OutputStream |
getStream()
Return the output stream associated with this Response. |
boolean |
isAppCommitted()
Application commit flag accessor. |
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 |
resetBuffer()
Reset the data buffer but not any status or header information. |
void |
setAppCommitted(boolean appCommitted)
Set the application commit flag. |
void |
setConnector(Connector connector)
Set the Connector through which this Response is returned. |
void |
setContext(Context context)
Set the Context with which this Response is associated. |
void |
setError()
Set the error flag. |
void |
setIncluded(boolean included)
Set the "processing inside an include" flag. |
void |
setRequest(Request request)
Set the Request with which this Response is associated. |
void |
setStream(java.io.OutputStream stream)
Set the output stream associated with this Response. |
void |
setSuspended(boolean suspended)
Set the suspended flag. |
Method Detail |
public Connector getConnector()
public void setConnector(Connector connector)
connector
- The new connectorpublic int getContentCount()
public Context getContext()
public void setContext(Context context)
context
- The associated Contextpublic void setAppCommitted(boolean appCommitted)
appCommitted
- The new application committed flag valuepublic boolean isAppCommitted()
public boolean getIncluded()
public void setIncluded(boolean included)
included
- true
if we are currently inside a
RequestDispatcher.include(), else false
public java.lang.String getInfo()
<description>/<version>
.
public Request getRequest()
public void setRequest(Request request)
request
- The new associated requestpublic javax.servlet.ServletResponse getResponse()
ServletResponse
for which this object
is the facade.
public java.io.OutputStream getStream()
public void setStream(java.io.OutputStream stream)
stream
- The new output streampublic void setSuspended(boolean suspended)
suspended
- The new suspended flag valuepublic boolean isSuspended()
public void setError()
public boolean isError()
public javax.servlet.ServletOutputStream createOutputStream() throws java.io.IOException
java.io.IOException
- if an input/output error occurspublic void finishResponse() throws java.io.IOException
java.io.IOException
- if an input/output error occurspublic int getContentLength()
public java.lang.String getContentType()
null
if no content type was set.
public java.io.PrintWriter getReporter()
public void recycle()
public void resetBuffer()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |