コード例 #1
0
        public void BindProtocolProviderType()
        {
            provider = null;

            if (!String.IsNullOrEmpty(this.URL))
            {
                protocolProviderType = ProtocolProviderFactory.GetProviderType(this.URL);
            }
        }
コード例 #2
0
        public IProtocolProvider BindProtocolProviderInstance(Downloader downloader)
        {
            if (protocolProviderType == null)
            {
                BindProtocolProviderType();
            }

            if (provider == null)
            {
                provider = ProtocolProviderFactory.CreateProvider(protocolProviderType, downloader);
            }

            return(provider);
        }