Package sonia.scm.web.cgi
Interface CGIStatusCodeHandler
public interface CGIStatusCodeHandler
Interface for handling return codes of processes
executed by the
CGIExecutor
.- Since:
- 1.15
-
Method Summary
Modifier and TypeMethodDescriptionvoid
handleStatusCode
(jakarta.servlet.http.HttpServletRequest request, int statusCode) Handles the return code of the process executed byCGIExecutor
.void
handleStatusCode
(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, OutputStream ouputStream, int statusCode) Handles the return code of the process executed byCGIExecutor
.
-
Method Details
-
handleStatusCode
void handleStatusCode(jakarta.servlet.http.HttpServletRequest request, int statusCode) Handles the return code of the process executed byCGIExecutor
. <b>Note:</b> This method is called when the process has already written to theOutputStream
.- Parameters:
request
- the http requeststatusCode
- process return code
-
handleStatusCode
void handleStatusCode(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, OutputStream ouputStream, int statusCode) throws IOException Handles the return code of the process executed byCGIExecutor
. <b>Note:</b> This method is only called when the process has not written to theOutputStream
. Do not callServletResponse.getWriter()
, because there was already a call toServletResponse.getOutputStream()
.- Parameters:
request
- the http requestresponse
- the http responseouputStream
- the servlet output streamstatusCode
- process return code- Throws:
IOException
-