public static void ValidateTenant(string tenantId, string applicationName, string sectionName, string key) { StringValidator.ValidateIsNullOrEmpty(tenantId, nameof(tenantId)); StringValidator.ValidateIsNullOrEmpty(sectionName, nameof(sectionName)); StringValidator.ValidateIsNullOrEmpty(key, nameof(key)); StringValidator.ValidateIsNullOrEmpty(applicationName, nameof(applicationName)); }
public ConfigurationProvider(string applicationName, ConfigurationBuilder configurationBuilder) { StringValidator.ValidateIsNullOrEmpty(applicationName, nameof(applicationName)); configurationBuilder.Apply(); _configurationStore = new CachedConfigurationStore(Defaults.DefaultProvider, Defaults.DefaultSensitiveDataProvider); _jsonSerializer = Defaults.DefaultSerializer; _applicationName = applicationName; }
public ConfigurationProvider(IConfigurationStore remoteConfigurationStore, IJsonSerializer serializer, string applicationName, ISensitiveDataProvider sensitiveDataProvider) { StringValidator.ValidateIsNullOrEmpty(applicationName, nameof(applicationName)); if (remoteConfigurationStore != null && serializer != null) { _configurationStore = new CachedConfigurationStore(remoteConfigurationStore, sensitiveDataProvider); _jsonSerializer = serializer; _applicationName = applicationName; } else { throw Errors.ClientSide.NoConfigurationProviderOrSerializer(); } }
public static void ValidateGlobal(string sectionName, string key) { StringValidator.ValidateIsNullOrEmpty(sectionName, nameof(sectionName)); StringValidator.ValidateIsNullOrEmpty(key, nameof(key)); }