/// <summary> /// </summary> /// <param name="compositData"></param> /// <returns></returns> public ITransport CreateTransport(URISupport.CompositeData compositData) { StringDictionary options = compositData.Parameters; FailoverTransport transport = CreateTransport(options); transport.Add(false, compositData.Components); return transport; }
public IProvider CreateProvider(Uri remoteUri) { URISupport.CompositeData compositeData = URISupport.ParseComposite(remoteUri); StringDictionary filteredProperties = PropertyUtil.FilterProperties(compositeData.Parameters, FAILOVER_OPTION_PREFIX); FailoverProvider failoverProvider = new FailoverProvider(compositeData.Components); PropertyUtil.SetProperties(failoverProvider, filteredProperties); return(failoverProvider); }
public IProvider CreateProvider(Uri remoteUri) { MockProviderConfiguration configuration = new MockProviderConfiguration(); MockRemotePeer remote = MockRemotePeer.Instance; remote?.ContextStats.RecordProviderCreated(); StringDictionary properties = URISupport.ParseParameters(remoteUri); StringDictionary mockProperties = PropertyUtil.FilterProperties(properties, "mock."); PropertyUtil.SetProperties(configuration, mockProperties); MockProvider provider = new MockProvider(remoteUri, configuration, remote); return(provider); }