Beispiel #1
0
        protected CloudPaymentsMiddlewareBase(
            RequestDelegate next,
            IOptions <CloudPaymentsOptions> options,
            ILoggerFactory loggerFactory,
            ITempDataDictionaryFactory tempDataFactory,
            ICloudPaymentsClient client,
            IAntiforgery antiforgery)
        {
            if (options == null)
            {
                throw new ArgumentNullException(nameof(options));
            }

            if (loggerFactory == null)
            {
                throw new ArgumentNullException(nameof(loggerFactory));
            }

            _next            = next ?? throw new ArgumentNullException(nameof(next));
            _options         = options.Value;
            _logger          = loggerFactory.CreateLogger <CloudPaymentsMiddleware>();
            _tempDataFactory = tempDataFactory ?? throw new ArgumentNullException(nameof(tempDataFactory));
            _client          = client ?? throw new ArgumentNullException(nameof(client));
            _antiforgery     = antiforgery ?? throw new ArgumentNullException(nameof(antiforgery));
        }
Beispiel #2
0
 public CloudPaymentsMiddleware3dSecure(
     RequestDelegate next,
     IOptions <CloudPaymentsOptions> options,
     ILoggerFactory loggerFactory,
     ITempDataDictionaryFactory tempDataFactory,
     ICloudPaymentsClient client,
     IAntiforgery antiforgery) : base(next, options, loggerFactory, tempDataFactory, client, antiforgery)
 {
 }
Beispiel #3
0
        public CloudPaymentsMiddleware(
            RequestDelegate next,
            IOptions <CloudPaymentsOptions> options,
            IOptions <CloudPaymentsClientOptions> clientOptions,
            ILoggerFactory loggerFactory,
            ITempDataDictionaryFactory tempDataFactory,
            ICloudPaymentsClient client,
            IAntiforgery antiforgery) : base(next, options, loggerFactory, tempDataFactory, client, antiforgery)
        {
            if (clientOptions == null)
            {
                throw new ArgumentNullException(nameof(clientOptions));
            }

            _clientOptions = clientOptions.Value;
        }