接口 CorsProcessor

所有已知实现类:
DefaultCorsProcessor

public interface CorsProcessor
A strategy that takes a request and a CorsConfiguration and updates the response.

This component is not concerned with how a CorsConfiguration is selected but rather takes follow-up actions such as applying CORS validation checks and either rejecting the response or adding CORS headers to the response.

从以下版本开始:
2019-12-23 21:01
作者:
Sebastien Deleuze, Rossen Stoyanchev, TODAY
另请参阅:
  • 方法概要

    修饰符和类型
    方法
    说明
    boolean
    process(CorsConfiguration configuration, RequestContext context)
    Process a request given a CorsConfiguration.
  • 方法详细资料

    • process

      boolean process(@Nullable CorsConfiguration configuration, RequestContext context) throws IOException
      Process a request given a CorsConfiguration.
      参数:
      configuration - the applicable CORS configuration (possibly null)
      context - the current HTTP context
      返回:
      false if the request is rejected, true otherwise
      抛出:
      IOException