Package org.apache.sling.rewriter.impl
Class ServletProcessingContext
- java.lang.Object
-
- org.apache.sling.rewriter.impl.ServletProcessingContext
-
- All Implemented Interfaces:
ProcessingContext
public class ServletProcessingContext extends Object implements ProcessingContext
An implementation of a processing context for a servlet.
-
-
Constructor Summary
Constructors Constructor Description ServletProcessingContext(org.apache.sling.api.SlingHttpServletRequest request, org.apache.sling.api.SlingHttpServletResponse response, org.apache.sling.api.SlingHttpServletResponse originalResponse, String contentType)
Initializes a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getContentType()
The content type of the response.OutputStream
getOutputStream()
The output stream.org.apache.sling.api.SlingHttpServletRequest
getRequest()
The current request.org.apache.sling.api.SlingHttpServletResponse
getResponse()
The current response.PrintWriter
getWriter()
The writer.
-
-
-
Constructor Detail
-
ServletProcessingContext
public ServletProcessingContext(org.apache.sling.api.SlingHttpServletRequest request, org.apache.sling.api.SlingHttpServletResponse response, org.apache.sling.api.SlingHttpServletResponse originalResponse, String contentType)
Initializes a new instance.
-
-
Method Detail
-
getContentType
public String getContentType()
Description copied from interface:ProcessingContext
The content type of the response.- Specified by:
getContentType
in interfaceProcessingContext
- See Also:
ProcessingContext.getContentType()
-
getRequest
public org.apache.sling.api.SlingHttpServletRequest getRequest()
Description copied from interface:ProcessingContext
The current request.- Specified by:
getRequest
in interfaceProcessingContext
- See Also:
ProcessingContext.getRequest()
-
getResponse
public org.apache.sling.api.SlingHttpServletResponse getResponse()
Description copied from interface:ProcessingContext
The current response.- Specified by:
getResponse
in interfaceProcessingContext
- See Also:
ProcessingContext.getResponse()
-
getWriter
public PrintWriter getWriter() throws IOException
Description copied from interface:ProcessingContext
The writer.- Specified by:
getWriter
in interfaceProcessingContext
- Throws:
IOException
- See Also:
ProcessingContext.getWriter()
-
getOutputStream
public OutputStream getOutputStream() throws IOException
Description copied from interface:ProcessingContext
The output stream.- Specified by:
getOutputStream
in interfaceProcessingContext
- Throws:
IOException
- See Also:
ProcessingContext.getOutputStream()
-
-