public Task <IBinding> TryCreateAsync(BindingProviderContext context) { WizHttpClientOptions option = (context.Parameter.GetCustomAttributes(false)[0] as WizHttpClientFactoryAttribute).Option; IBinding binding = new WizHttpClientFactoryBinding(option, _httpClientFactory); return(Task.FromResult(binding)); }
public WizHttpClientFactoryAttribute(WizHttpClientOptions option) { Option = option; }
public WizHttpClientFactoryValueProvider(WizHttpClientOptions option, HttpRequest request, IHttpClientFactory httpClientFactory) { _request = request; _httpClientFactory = httpClientFactory; _option = option; }
public WizHttpClientFactoryBinding(WizHttpClientOptions option, IHttpClientFactory httpClientFactory) { this._option = option; this._httpClientFactory = httpClientFactory; }