public WatsonVisualRecognitionService(IHttpProxyClientService httpProxyClientService, IConfiguration configuration) { _httpProxyClientService = httpProxyClientService; Configuration = configuration; _watsonUri = $"{Configuration["Watson:BaseUri"]}?{Configuration["Watson:Version"]}"; _tokenUri = Configuration["Watson:TokenUri"]; }
public WatsonSpeechToTextService(IHttpProxyClientService httpProxyClientService, IOptions <MyConfig> config) { _httpProxyClientService = httpProxyClientService; _config = config; _username = _config.Value.WatsonUsername; _password = _config.Value.WatsonPassword; }
public WatsonTextTranslationService(IHttpProxyClientService httpProxyClientService, IOptions <MyConfig> config) { _httpProxyClientService = httpProxyClientService; _config = config; _username = _config.Value.WatsonUsernameTextTranslation; _password = _config.Value.WatsonPasswordTextTranslation; }
public AzureAuthenticationService(IHttpProxyClientService proxyClientService, IOptions <MyConfig> config) { _proxyClientService = proxyClientService; _config = config; _subscriptionKey = _config.Value.BingSubscriptionKey; _token = FetchToken(FetchTokenUri, _subscriptionKey).Result; // renew the token every specfied minutes _accessTokenRenewer = new Timer(OnTokenExpiredCallback, this, TimeSpan.FromMinutes(RefreshTokenDuration), TimeSpan.FromMilliseconds(-1)); }
public AzureSpeechTranslatorService(IHttpProxyClientService httpProxyClientService) : this() { _httpProxyClientService = httpProxyClientService; }
public AwsService(IAmazonUploader amazonUploader, IAmazonTranscribeService amazonTranscribeService, IHttpProxyClientService httpProxyClientService) { _amazonUploaderService = amazonUploader; _amazonTranscribeService = amazonTranscribeService; _httpProxyClientService = httpProxyClientService; }
/// <summary> /// Конструктор. /// </summary> /// <param name="httpProxyClientService">Параметры proxy.</param> /// <param name="settingsService">Поставщик параметров.</param> public RssService(IHttpProxyClientService httpProxyClientService, ISettingsService settingsService) { options = settingsService.GetSettings(); this.httpProxyClientService = httpProxyClientService; }
public AzureTextTranslationService(IHttpProxyClientService httpProxyClientService, IOptions <MyConfig> config) : this() { _httpProxyClientService = httpProxyClientService; _config = config; _azureKey = _config.Value.AzureTextTranslationKey; }
public BingSpeechService(IAzureAuthenticationService azureAzureAuthenticationService, IHttpProxyClientService httpProxyClientService) { _azureAuthenticationService = azureAzureAuthenticationService; _httpProxyClientService = httpProxyClientService; }