示例#1
0
 public ErrorFilterImpl(IClientErrorFactory clientErrorFactory, ILoggerFactory loggerFactory, bool handleMvcRequests, bool handleApiRequests, ErrorFilterOptions options)
 {
     _clientErrorFactory = clientErrorFactory ?? throw new ArgumentNullException(nameof(clientErrorFactory));
     _logger             = loggerFactory.CreateLogger <ErrorFilterAttribute>();
     _handleMvcRequests  = handleMvcRequests;
     _handleApiRequests  = handleApiRequests;
     _options            = options;
 }
示例#2
0
 public ErrorFilterAttribute(bool handleMvcRequests, bool handleApiRequests, ErrorFilterOptions options)
     : base(typeof(ErrorFilterImpl))
 {
     Arguments = new object[] { handleMvcRequests, handleApiRequests, options };
 }