Package com.aspectran.web.support.cors
Interface CorsProcessor
-
- All Known Implementing Classes:
AbstractCorsProcessor,DefaultCorsProcessor
public interface CorsProcessorProcess an incoming cross-origin (CORS) requests. Encapsulates the CORS processing logic as specified by the W3C candidate recommendation from 2013-01-29.- Since:
- 2.3.0
- See Also:
- CORS W3C recommandation
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidprocessActualRequest(com.aspectran.core.activity.Translet translet)Process a simple or actual CORS request.voidprocessPreflightRequest(com.aspectran.core.activity.Translet translet)Process a preflight CORS request.voidsendError(com.aspectran.core.activity.Translet translet)Sends an error response to the client using the specified status.
-
-
-
Method Detail
-
processActualRequest
void processActualRequest(com.aspectran.core.activity.Translet translet) throws CorsException, java.io.IOExceptionProcess a simple or actual CORS request.- Parameters:
translet- the Translet instance- Throws:
CorsException- if the request is invalid or deniedjava.io.IOException- in case of I/O errors
-
processPreflightRequest
void processPreflightRequest(com.aspectran.core.activity.Translet translet) throws CorsException, java.io.IOExceptionProcess a preflight CORS request.CORS specification: PreflightRequest
- Parameters:
translet- the Translet instance- Throws:
CorsException- if the request is invalid or deniedjava.io.IOException- in case of I/O errors
-
sendError
void sendError(com.aspectran.core.activity.Translet translet) throws java.io.IOExceptionSends an error response to the client using the specified status.- Parameters:
translet- the Translet instance- Throws:
java.io.IOException- in case of I/O errors
-
-