/// <summary> /// Contstructor /// </summary> /// <param name="settings">Options for this instance</param> /// <param name="cache">Cache implementation to use</param> /// <param name="adressRegistry">AdressRegistry implementation to use</param> public CollaborationProtocolRegistry( CollaborationProtocolRegistrySettings settings, IDistributedCache cache, IAddressRegistry adressRegistry) { if (settings == null) { throw new ArgumentNullException(nameof(settings)); } if (cache == null) { throw new ArgumentNullException(nameof(cache)); } if (adressRegistry == null) { throw new ArgumentNullException(nameof(adressRegistry)); } _settings = settings; _cache = cache; _adressRegistry = adressRegistry; _invoker = new SoapServiceInvoker(settings.WcfConfiguration); _invoker.SetClientCredentials(_settings.UserName, _settings.Password); CertificateValidator = new CertificateValidator(_settings.UseOnlineRevocationCheck); }
/// <summary> /// Contstructor /// </summary> /// <param name="settings">Options for this instance</param> /// <param name="cache">Cache implementation to use</param> public AddressRegistry( AddressRegistrySettings settings, IDistributedCache cache) { if (settings == null) { throw new ArgumentNullException(nameof(settings)); } if (cache == null) { throw new ArgumentNullException(nameof(cache)); } _settings = settings; _cache = cache; _invoker = new SoapServiceInvoker(settings.WcfConfiguration); _invoker.SetClientCredentials(_settings.UserName, _settings.Password); }