public Call(Guid clientProxyId, IServiceProvider serviceProvider, ContractInfo contract, IOnceCallFactory factory, int timeoutInterval, string optionsName) { _clientProxyId = clientProxyId; _serviceProvider = serviceProvider; _contract = contract; _factory = factory; _timeoutInterval = timeoutInterval; _optionsName = optionsName; if (serviceProvider != null) { var middlewareOptions = _serviceProvider.GetService <IOptions <ClientMiddlewareOptions> >().Value; _middlewareBuilder = new ClientMiddlewareBuilder(middlewareOptions, serviceProvider); } }
public CallFactory(Type tService, Guid id, IServiceProvider serviceProvider, ClientMiddlewareOptions options, IActionExecutingContextAccessor accessor, IOnceCallFactory onceCallFactory, NClientOptions nClientOptions, Dictionary <string, object?> additionHeader, string?optionsName) { _tService = tService; _id = id; _serviceProvider = serviceProvider; _options = options; _accessor = accessor; _onceCallFactory = onceCallFactory; _nClientOptions = nClientOptions; _additionHeader = additionHeader; _optionsName = optionsName; }
public Call(Guid clientProxyId, ContractInfo contractInfo, IServiceProvider serviceProvider, ClientMiddlewareOptions middlewareOptions, IActionExecutingContextAccessor actionExecutingContextAccessor, IOnceCallFactory factory, int timeoutInterval, bool forwardHeader, string?optionsName) { _clientProxyId = clientProxyId; _serviceProvider = serviceProvider; _actionExecutingContextAccessor = actionExecutingContextAccessor; _contract = contractInfo; _factory = factory; _timeoutInterval = timeoutInterval; _forwardHeader = forwardHeader; _optionsName = optionsName; _middlewareBuilder = new ClientMiddlewareBuilder(middlewareOptions, serviceProvider); }