/// <summary> /// 构造ApiExecutionContextHandler /// </summary> /// <param name="attr"></param> public ApiExecutionContextHandler(ApiExecutionFilterAttribute attr) { ExceptionHandler = new ApiExceptionHandler(); ModelStateValidationErrorHandler = new ApiModelStateValidationErrorHandler(); UnauthorizedRequestHandler = new ApiUnauthorizedRequestHandler(); this.AssociateFilter = attr; }