• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# IClientChannelSinkProvider类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中IClientChannelSinkProvider的典型用法代码示例。如果您正苦于以下问题:C# IClientChannelSinkProvider类的具体用法?C# IClientChannelSinkProvider怎么用?C# IClientChannelSinkProvider使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



IClientChannelSinkProvider类属于命名空间,在下文中一共展示了IClientChannelSinkProvider类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: HttpChannel

        } // HttpChannel

        public HttpChannel(IDictionary properties, 
                           IClientChannelSinkProvider clientSinkProvider,
                           IServerChannelSinkProvider serverSinkProvider)
        {
            Hashtable clientData = new Hashtable();
            Hashtable serverData = new Hashtable();
        
            // divide properties up for respective channels
            if (properties != null)
            {            
                foreach (DictionaryEntry entry in properties)
                {
                    switch ((String)entry.Key)
                    {
                    // general channel properties
                    case "name": _channelName = (String)entry.Value; break;
                    case "priority": _channelPriority = Convert.ToInt32((String)entry.Value, CultureInfo.InvariantCulture); break;
                    case "secure": _secure = Convert.ToBoolean(entry.Value, CultureInfo.InvariantCulture); 
                                    clientData["secure"] = entry.Value;
                                    serverData["secure"] = entry.Value;
                                    break;
                    default: 
                        clientData[entry.Key] = entry.Value;
                        serverData[entry.Key] = entry.Value;
                        break;
                    }
                }
            }

            _clientChannel = new HttpClientChannel(clientData, clientSinkProvider);
            _serverChannel = new HttpServerChannel(serverData, serverSinkProvider);
        } // HttpChannel
开发者ID:gbarnett,项目名称:shared-source-cli-2.0,代码行数:34,代码来源:combinedhttpchannel.cs


示例2: TcpClientChannel

		public TcpClientChannel (IDictionary properties, IClientChannelSinkProvider sinkProvider)
		{
			if (properties != null) {
				object val = properties ["name"];
				if (val != null) name = val as string;
			
				val = properties ["priority"];
				if (val != null) priority = Convert.ToInt32 (val);
			}
			
			if (sinkProvider != null)
			{
				_sinkProvider = sinkProvider;

				// add the tcp provider at the end of the chain
				IClientChannelSinkProvider prov = sinkProvider;
				while (prov.Next != null) prov = prov.Next;
				prov.Next = new TcpClientTransportSinkProvider ();

				// Note: a default formatter is added only when
				// no sink providers are specified in the config file.
			}
			else
			{
				_sinkProvider = new BinaryClientFormatterSinkProvider ();
				_sinkProvider.Next = new TcpClientTransportSinkProvider ();
			}

		}
开发者ID:nlhepler,项目名称:mono,代码行数:29,代码来源:TcpClientChannel.cs


示例3: TcpClientChannel

        // constructor used by config file
        /// <include file='doc\TcpClientChannel.uex' path='docs/doc[@for="TcpClientChannel.TcpClientChannel2"]/*' />
        public TcpClientChannel(IDictionary properties, IClientChannelSinkProvider sinkProvider)
        {
            if (properties != null)
            {
                foreach (DictionaryEntry entry in properties)
                {
                    switch ((String)entry.Key)
                    {
                    case "name": _channelName = (String)entry.Value; break;
                    case "priority": _channelPriority = Convert.ToInt32(entry.Value); break;

                    default: 
                         throw new ArgumentException(
                            String.Format(
                                CoreChannel.GetResourceString(
                                    "Remoting_Channels_BadCtorArgs"),
                                entry.Key));
                    }
                }
            }

            _sinkProvider = sinkProvider;

            SetupChannel();
        } // TcpClientChannel
开发者ID:ArildF,项目名称:masters,代码行数:27,代码来源:tcpclientchannel.cs


示例4: ClientWorkflowInvoker

		/// <summary></summary>
		public ClientWorkflowInvoker(IDictionary properties, IClientChannelSinkProvider clientSinkProvider) 
		{	
			try 
			{	
                // configuration file
			    if(properties.Contains("timeout"))
                    _TimeOut = Convert.ToInt32(properties["timeout"]);
                if (properties.Contains("name"))
                    _ChannelName = Convert.ToString(properties["name"]);
                if (properties.Contains("callcontextActor"))
                    _CallContextActor = Convert.ToString(properties["callcontextActor"]);
             
				// channel provider
				_Provider = clientSinkProvider == null ? new BinaryClientFormatterSinkProvider() : clientSinkProvider;

				// add the ClientWorkflowInvokerProvider at the end
				IClientChannelSinkProvider provider = _Provider;
                while (provider.Next != null)
                {
                    provider = provider.Next;
                }
				provider.Next = new ClientWorkflowInvokerProvider();
			}
			catch(Exception ex) 
			{
                Trace.WriteLine(ex);
			}
		}
开发者ID:spzenk,项目名称:sfdocsamples,代码行数:29,代码来源:ClientWorkflowInvoker.cs


示例5: IpcClientChannel

        } // IpcClientChannel


        public IpcClientChannel(String name, IClientChannelSinkProvider sinkProvider)
        {
            _channelName = name;
            _sinkProvider = sinkProvider;

            SetupChannel();
        }
开发者ID:JianwenSun,项目名称:cc,代码行数:10,代码来源:IpcClientChannel.cs


示例6: HttpClientChannel

		public HttpClientChannel(String name, IClientChannelSinkProvider sinkProvider)
		{
			if(name != null)
				_channelName = name;
			
			SetupProvider (sinkProvider, null);
		}
开发者ID:jjenki11,项目名称:blaze-chem-rendering,代码行数:7,代码来源:HttpClientChannel.cs


示例7: Start

        /// <summary>
        /// Start connection with specified engine interface
        /// </summary>
        /// <param name="typeEngineInterface">Type of engine interface</param>
        /// <param name="urlClient">Asscoiated URL</param>
        /// <param name="ensureSecurity">Remoting security attribute</param>
        public void Start(string urlClient, bool ensureSecurity, uint timeOut, Type iProxyType)
        {
            Trace.TraceInformation("Configuring client connection");

            _ensureSecurity = ensureSecurity;

            IDictionary t = new Hashtable();
            t.Add("timeout", timeOut);
            t.Add("name", urlClient);

            #if MONO
            _sinkProvider = new BinaryClientFormatterSinkProvider();
            #endif

            #if MONO
            /* MoMA moans about this line, but not clear why?
            Message	10	MonoTodo: void HttpClientChannel..ctor(IDictionary, IClientChannelSinkProvider)
            Reason: Handle the machineName, proxyName, proxyPort, servicePrincipalName, useAuthenticatedConnectionSharing properties	D:\Source\Projects\FluidEarth_Trunk\FluidEarth\SDK\src\ConnectionHttp.cs	148	14	PluginInterfaces
            */
            _channel = new HttpClientChannel(t, _sinkProvider);
            #else
            // need to make ChannelNames unique so need to use this
            // constructor even though we dont care about the sink provider
            _channel = new HttpClientChannel(t, _sinkProvider);
            #endif

            ChannelServices.RegisterChannel(_channel, _ensureSecurity);

            Trace.TraceInformation("Configured client connection");

            _base = (IBase)Activator.GetObject(iProxyType, urlClient);

            Trace.TraceInformation("Acquired proxy");
        }
开发者ID:CNH-Hyper-Extractive,项目名称:parallel-sdk,代码行数:40,代码来源:RemotingConnectionHttp.cs


示例8: UdpClientChannel

 public UdpClientChannel(IDictionary properties, IClientChannelSinkProvider provider)
 {
     ChannelName = properties.GetValue("name", UdpChannelHelper.DefaultName);
     ChannelPriority = properties.GetValue("priority", UdpChannelHelper.DefaultPriority);
     ClientSinkProvider = provider ?? UdpChannelHelper.CreateClientSinkProvider();
     SetupClientProviderChain(ClientSinkProvider, new UdpClientChannelSinkProvider());
 }
开发者ID:yallie,项目名称:zyan,代码行数:7,代码来源:UdpClientChannel.cs


示例9: IpcClientChannel

        /// <summary>
        /// Creates a client channel.
        /// </summary>
        /// <param name="properties">The properties.</param>
        /// <param name="sinkProvider">The provider</param>
        public IpcClientChannel(IDictionary properties, IClientChannelSinkProvider provider)
        {
            if (properties != null) 
            {
                foreach (DictionaryEntry e in properties) 
                {
                    switch ((string)e.Key) 
                    {
                        case "name":
                            channelName = (string)e.Value;
                            break;
                        case "priority":
                            channelPriority = Convert.ToInt32(e.Value);
                            break;
                    }
                }
            }

            if (provider == null) 
            {
                clientProvider = new BinaryClientFormatterSinkProvider();
                clientProvider.Next = new IpcClientChannelSinkProvider();
            }
            else 
            {
                // add us to the sink chain.
                clientProvider = provider;
                IClientChannelSinkProvider p;
                for (p = clientProvider; p.Next != null; p = p.Next) {}
                p.Next = new IpcClientChannelSinkProvider();
            }
                                        
        }
开发者ID:Profit0004,项目名称:mono,代码行数:38,代码来源:IpcClientChannel.cs


示例10: IpcClientChannel

 public IpcClientChannel(string name, IClientChannelSinkProvider sinkProvider)
 {
     this._channelPriority = 1;
     this._channelName = "ipc client";
     this._channelName = name;
     this._sinkProvider = sinkProvider;
     this.SetupChannel();
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:8,代码来源:IpcClientChannel.cs


示例11: IpcClientChannel

 public IpcClientChannel (IDictionary properties,
                          IClientChannelSinkProvider sinkProvider)
 {
         if (IpcChannel.IsUnix)
                 _innerChannel = new Unix.IpcClientChannel (properties, sinkProvider);
         else
                 _innerChannel = new Win32.IpcClientChannel (properties, sinkProvider);
 }
开发者ID:nlhepler,项目名称:mono,代码行数:8,代码来源:IpcClientChannel.cs


示例12: IpcChannel

 /// <summary>
 /// Creates both server and client channels.
 /// </summary>
 /// <param name="properties">The channel properties.</param>
 /// <param name="clientProvider">The client sink provider. It may be <c>null</c>.</param>
 /// <param name="serverProvider">The server sink provider. It may be <c>null</c>.</param>
 public IpcChannel(IDictionary properties,
     IClientChannelSinkProvider clientProvider,
     IServerChannelSinkProvider serverProvider
     )
 {
     clientChannel = new IpcClientChannel(properties, clientProvider);
     serverChannel = new IpcServerChannel(properties, serverProvider);
 }
开发者ID:Profit0004,项目名称:mono,代码行数:14,代码来源:IpcChannel.cs


示例13: PipeChannel

 public PipeChannel(
             IDictionary properties, 
             IClientChannelSinkProvider clientProviderChain,
             IServerChannelSinkProvider serverProviderChain
         )
 {
     _clientChannel = new PipeClientChannel(properties, clientProviderChain);
       _serverChannel = new PipeServerChannel(properties, serverProviderChain);
 }
开发者ID:hostitherepc,项目名称:Fork-1,代码行数:9,代码来源:PipeChannel.cs


示例14: IpcChannel

 public IpcChannel (IDictionary properties,
                    IClientChannelSinkProvider clientSinkProvider,
                    IServerChannelSinkProvider serverSinkProvider)
 {
         if (IsUnix)
                 _innerChannel = new Unix.IpcChannel (properties, clientSinkProvider, serverSinkProvider);
         else
                 _innerChannel = new Win32.IpcChannel (properties, clientSinkProvider, serverSinkProvider);
 }
开发者ID:calumjiao,项目名称:Mono-Class-Libraries,代码行数:9,代码来源:IpcChannel.cs


示例15: PipeClientChannel

 public PipeClientChannel(
                           IDictionary properties, 
                           IClientChannelSinkProvider clientProviderChain
                          )
 {
     InitDefaults();
     InitProperties(properties);
     InitProviders(clientProviderChain);
 }
开发者ID:hostitherepc,项目名称:Fork-1,代码行数:9,代码来源:PipeClientChannel.cs


示例16: TcpClientChannel

		public TcpClientChannel (string name, IClientChannelSinkProvider sinkProvider)
		{
			this.name = name;
			_sinkProvider = sinkProvider;

			// add the tcp provider at the end of the chain
			IClientChannelSinkProvider prov = sinkProvider;
			while (prov.Next != null) prov = prov.Next;
			prov.Next = new TcpClientTransportSinkProvider ();
		}
开发者ID:jjenki11,项目名称:blaze-chem-rendering,代码行数:10,代码来源:TcpClientChannel.cs


示例17: CORBAClientChannel

		public CORBAClientChannel (IDictionary properties, IClientChannelSinkProvider sinkProvider)
		{
			priority = 1;
			sink_provider = sinkProvider;

			// add the tcp provider at the end of the chain
			IClientChannelSinkProvider prov = sinkProvider;
			while (prov.Next != null) prov = prov.Next;
			prov.Next = new CORBAClientTransportSinkProvider ();
		}
开发者ID:nlhepler,项目名称:mono,代码行数:10,代码来源:CORBAClientChannel.cs


示例18: ClientChannelSinkProviderForParticularServer

        internal ClientChannelSinkProviderForParticularServer(IClientChannelSinkProvider upstream, string id)
        {
            if (upstream == null) 
                throw new ArgumentNullException("upstream");

            if (String.IsNullOrEmpty(id)) 
                throw new ArgumentNullException("id");

            m_Upstream = upstream;
            m_Url = string.Format("ipc://{0}", id);
        }
开发者ID:jotero25,项目名称:RedGate.AppHost,代码行数:11,代码来源:ClientChannelSinkProviderForParticularServer.cs


示例19: HttpChannel

		public HttpChannel (IDictionary properties,
			IClientChannelSinkProvider clientSinkProvider,
			IServerChannelSinkProvider serverSinkProvider)
		{
			if (properties != null && properties.Contains ("name")) {
				this.name = (string)properties["name"];
			}

			client = new HttpClientChannel (properties, clientSinkProvider);
			server = new HttpServerChannel (properties, serverSinkProvider);
		}
开发者ID:Profit0004,项目名称:mono,代码行数:11,代码来源:HttpChannel.cs


示例20: UdpChannel

 public UdpChannel(IDictionary properties, IClientChannelSinkProvider clientChain, IServerChannelSinkProvider serverChain)
 {
     if (serverChain != null || (properties != null && properties.Contains("port")))
     {
         ServerChannel = new UdpServerChannel(properties, serverChain);
     }
     else
     {
         ClientChannel = new UdpClientChannel(properties, clientChain);
     }
 }
开发者ID:yallie,项目名称:zyan,代码行数:11,代码来源:UdpChannel.cs



注:本文中的IClientChannelSinkProvider类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# IClientConfiguration类代码示例发布时间:2022-05-24
下一篇:
C# IClientChannel类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap