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

C# Messaging.LogicalCallContext类代码示例

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

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



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

示例1: ADAsyncWorkItem

 internal ADAsyncWorkItem(IMessage reqMsg, IMessageSink nextSink, IMessageSink replySink)
 {
     this._reqMsg = reqMsg;
     this._nextSink = nextSink;
     this._replySink = replySink;
     this._callCtx = CallContext.GetLogicalCallContext();
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:7,代码来源:ADAsyncWorkItem.cs


示例2: Read

 public void Read(__BinaryParser input)
 {
     this.messageEnum = (MessageEnum) input.ReadInt32();
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.NoReturnValue))
     {
         this.returnValue = null;
     }
     else if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ReturnValueVoid))
     {
         this.returnValue = instanceOfVoid;
     }
     else if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ReturnValueInline))
     {
         this.returnValue = IOUtil.ReadWithCode(input);
     }
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ContextInline))
     {
         this.scallContext = (string) IOUtil.ReadWithCode(input);
         LogicalCallContext context = new LogicalCallContext {
             RemotingData = { LogicalCallID = this.scallContext }
         };
         this.callContext = context;
     }
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ArgsInline))
     {
         this.args = IOUtil.ReadArgs(input);
     }
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:28,代码来源:BinaryMethodReturn.cs


示例3: AsyncWorkItem

 internal AsyncWorkItem(IMessage reqMsg, IMessageSink replySink, Context oldCtx, ServerIdentity srvID)
 {
     this._reqMsg = reqMsg;
     this._replySink = replySink;
     this._oldCtx = oldCtx;
     this._callCtx = CallContext.GetLogicalCallContext();
     this._srvID = srvID;
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:8,代码来源:AsyncWorkItem.cs


示例4: SetLogicalCallContext

 // Sets the given logical call context object on the thread.
 // Returns the previous one.
 internal static LogicalCallContext SetLogicalCallContext(
     LogicalCallContext callCtx)
 {
     ExecutionContext ec = Thread.CurrentThread.GetMutableExecutionContext();
     LogicalCallContext prev = ec.LogicalCallContext;
     ec.LogicalCallContext = callCtx;
     return prev;
 }
开发者ID:krytht,项目名称:DotNetReferenceSource,代码行数:10,代码来源:CallContext.cs


示例5: ReturnMessage

	public ReturnMessage(Object ret, Object[] outArgs, int outArgsCount,
						 LogicalCallContext callCtx, IMethodCallMessage mcm)
			{
				this.ret = ret;
				this.outArgs = outArgs;
				this.outArgsCount = outArgsCount;
				this.callCtx = callCtx;
				this.mcm = mcm;
			}
开发者ID:jjenki11,项目名称:blaze-chem-rendering,代码行数:9,代码来源:ReturnMessage.cs


示例6: MessageMethodInvocation

 /// <summary>
 /// Extracts and interprets fields from "IMessage"
 /// 
 /// Samle IMassage when the method "ToString" is called:
 ///     msg.Properties["__Uri"]	
 ///         null	
 ///         object
 ///     msg.Properties["__MethodName"]	
 ///         "ToString"	
 ///         object {string}
 ///     msg.Properties["__MethodSignature"]	
 ///         {System.Type[0]}	
 ///         object {System.Type[]}
 ///     msg.Properties["__TypeName"]	
 ///         "System.Object, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"	
 ///         object {string}
 ///     msg.Properties["__Args"]	
 ///         {object[0]}	
 ///         object {object[]}
 ///     msg.Properties["__CallContext"]	
 ///         {System.Runtime.Remoting.Messaging.LogicalCallContext}	
 ///         object {System.Runtime.Remoting.Messaging.LogicalCallContext}
 ///     Type.GetType((string)msg.Properties["__TypeName"]) == typeof(object)	
 ///         true	
 ///         bool
 /// </summary>
 /// <param name="msg"></param>
 public MessageMethodInvocation(IMessage msg)
     : base(msg.Properties["__TypeName"] as string,
          msg.Properties["__MethodName"] as string,
          msg.Properties["__MethodSignature"] as Type[],
          msg.Properties["__Args"] as object[])
 {
     _message = msg;
     _callContext = _message.Properties["__CallContext"] as LogicalCallContext;
 }
开发者ID:frenzqse,项目名称:loom-csharp-visualstudio,代码行数:36,代码来源:MessageMethodInvocation.cs


示例7: ReturnMessage

		public ReturnMessage (Exception e, IMethodCallMessage mcm)
		{
			_exception = e;
			
			if (mcm != null) {
				_methodBase = mcm.MethodBase;
				_callCtx = mcm.LogicalCallContext;
			}
			_args = new object[0];	// .NET does this
		}
开发者ID:runefs,项目名称:Marvin,代码行数:10,代码来源:ReturnMessage.cs


示例8: ExecutionContext

		private ExecutionContext (ExecutionContext ec)
		{
#if !MOBILE
			if (ec._sc != null)
				_sc = new SecurityContext (ec._sc);
#endif
			if (ec._lcc != null)
				_lcc = (LogicalCallContext) ec._lcc.Clone ();

			_suppressFlow = ec._suppressFlow;
			_capture = true;
		}
开发者ID:KonajuGames,项目名称:SharpLang,代码行数:12,代码来源:ExecutionContext.cs


示例9: MethodResponse

	internal MethodResponse(IMethodReturnMessage mrm)
			{
				outArgs = mrm.OutArgs;
				methodName = mrm.MethodName;
				typeName = mrm.TypeName;
				uri = mrm.Uri;
				hasVarArgs = mrm.HasVarArgs;
				context = mrm.LogicalCallContext;
				method = mrm.MethodBase;
				exception = mrm.Exception;
				returnValue = mrm.ReturnValue;
			}
开发者ID:jjenki11,项目名称:blaze-chem-rendering,代码行数:12,代码来源:MethodResponse.cs


示例10: ExecutionContext

 private ExecutionContext(SerializationInfo info, StreamingContext context)
 {
     SerializationInfoEnumerator enumerator = info.GetEnumerator();
     while (enumerator.MoveNext())
     {
         if (enumerator.Name.Equals("LogicalCallContext"))
         {
             this._logicalCallContext = (System.Runtime.Remoting.Messaging.LogicalCallContext) enumerator.Value;
         }
     }
     this.Thread = System.Threading.Thread.CurrentThread;
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:12,代码来源:ExecutionContext.cs


示例11: MethodMessage

 internal MethodMessage(Type interfaceType, string methodName, object[] args, string identity, bool responseRequired)
 {
     this.interfaceType = interfaceType;
     this.methodName = methodName;
     this.args = args;
     this.callContext = GetLogicalCallContext();
     if (responseRequired)
     {
         this.returnValueSignalEvent = new ManualResetEvent(false);
     }
     this.PopulateIdentity(this.callContext, identity);
     this.Clone();
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:13,代码来源:MethodMessage.cs


示例12: ReturnMessage

		public ReturnMessage (object ret, object [] outArgs,
			       int outArgsCount, LogicalCallContext callCtx,
			       IMethodCallMessage mcm)
		{
			// outArgCount tells how many values of outArgs are valid

			_returnValue = ret;
			_args = outArgs;
			_callCtx = callCtx;
			if (mcm != null) {
				_uri = mcm.Uri;
				_methodBase = mcm.MethodBase;
			}
			if (_args == null) _args = new object [outArgsCount];
		}
开发者ID:Profit0004,项目名称:mono,代码行数:15,代码来源:ReturnMessage.cs


示例13: Read

 internal void Read(__BinaryParser input)
 {
     this.messageEnum = (MessageEnum) input.ReadInt32();
     this.methodName = (string) IOUtil.ReadWithCode(input);
     this.typeName = (string) IOUtil.ReadWithCode(input);
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ContextInline))
     {
         this.scallContext = (string) IOUtil.ReadWithCode(input);
         LogicalCallContext context = new LogicalCallContext {
             RemotingData = { LogicalCallID = this.scallContext }
         };
         this.callContext = context;
     }
     if (IOUtil.FlagTest(this.messageEnum, MessageEnum.ArgsInline))
     {
         this.args = IOUtil.ReadArgs(input);
     }
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:18,代码来源:BinaryMethodCall.cs


示例14: SerializeContextElements

 private void SerializeContextElements(CdrOutputStream targetStream,
                                       LogicalCallContext callContext,
                                       Serializer contextElementSer) {
     // if no context elements specified, don't serialise a context sequence.
     if (m_contextElementKeys.Length > 0) {
         string[] contextSeq = new string[m_contextElementKeys.Length * 2];
         for (int i = 0; i < m_contextElementKeys.Length; i++) {
             string contextKey =
                 m_contextElementKeys[i];
             contextSeq[i * 2] = contextKey;
             if (callContext.GetData(contextKey) != null) {
                 contextSeq[i * 2 + 1] = callContext.GetData(contextKey).ToString();
             } else {
                 contextSeq[i * 2 + 1] = "";
             }
         }
         contextElementSer.Serialize(contextSeq, targetStream);
     }
 }
开发者ID:JnS-Software-LLC,项目名称:iiop-net,代码行数:19,代码来源:ArgumentsSerializer.cs


示例15: BinaryMethodCallMessage

        internal BinaryMethodCallMessage(String uri, String methodName, String typeName, Object[] args, Object methodSignature, LogicalCallContext callContext, Object[] properties)
        {
            _methodName = methodName;
            _typeName = typeName;
            //_uri = uri;
            if (args == null)
                args = new Object[0];

            _inargs = args;
            _args = args;
            _methodSignature = methodSignature;
            if (callContext == null)
                _logicalCallContext = new LogicalCallContext();
            else
                _logicalCallContext = callContext;

            _properties = properties;

        }
开发者ID:ArildF,项目名称:masters,代码行数:19,代码来源:binarymethodmessage.cs


示例16: MethodCall

		internal MethodCall (CADMethodCallMessage msg) 
		{
			_uri = string.Copy (msg.Uri);
			
			// Get unmarshalled arguments
			ArrayList args = msg.GetArguments ();

			_args = msg.GetArgs (args);
			_callContext = msg.GetLogicalCallContext (args);
			if (_callContext == null)
				_callContext = new LogicalCallContext ();
	
			_methodBase = msg.GetMethod ();
			
			Init();

			if (msg.PropertiesCount > 0)
				CADMessageBase.UnmarshalProperties (Properties, msg.PropertiesCount, args);
		}
开发者ID:jack-pappas,项目名称:mono,代码行数:19,代码来源:MethodCall.cs


示例17: BinaryMethodReturnMessage

 internal BinaryMethodReturnMessage(object returnValue, object[] args, System.Exception e, System.Runtime.Remoting.Messaging.LogicalCallContext callContext, object[] properties)
 {
     this._returnValue = returnValue;
     if (args == null)
     {
         args = new object[0];
     }
     this._outargs = args;
     this._args = args;
     this._exception = e;
     if (callContext == null)
     {
         this._logicalCallContext = new System.Runtime.Remoting.Messaging.LogicalCallContext();
     }
     else
     {
         this._logicalCallContext = callContext;
     }
     this._properties = properties;
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:20,代码来源:BinaryMethodReturnMessage.cs


示例18: Clone

 public object Clone()
 {
     LogicalCallContext context = new LogicalCallContext();
     if (this.m_RemotingData != null)
     {
         context.m_RemotingData = (CallContextRemotingData) this.m_RemotingData.Clone();
     }
     if (this.m_SecurityData != null)
     {
         context.m_SecurityData = (CallContextSecurityData) this.m_SecurityData.Clone();
     }
     if (this.m_HostContext != null)
     {
         context.m_HostContext = this.m_HostContext;
     }
     if (this.HasUserData)
     {
         IDictionaryEnumerator enumerator = this.m_Datastore.GetEnumerator();
         if (this.m_IsCorrelationMgr)
         {
             while (enumerator.MoveNext())
             {
                 string key = (string) enumerator.Key;
                 if (key.Equals("System.Diagnostics.Trace.CorrelationManagerSlot"))
                 {
                     context.Datastore[key] = ((ICloneable) enumerator.Value).Clone();
                 }
                 else
                 {
                     context.Datastore[key] = enumerator.Value;
                 }
             }
             return context;
         }
         while (enumerator.MoveNext())
         {
             context.Datastore[(string) enumerator.Key] = enumerator.Value;
         }
     }
     return context;
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:41,代码来源:LogicalCallContext.cs


示例19: BinaryMethodCallMessage

 internal BinaryMethodCallMessage(string uri, string methodName, string typeName, Type[] instArgs, object[] args, object methodSignature, System.Runtime.Remoting.Messaging.LogicalCallContext callContext, object[] properties)
 {
     this._methodName = methodName;
     this._typeName = typeName;
     if (args == null)
     {
         args = new object[0];
     }
     this._inargs = args;
     this._args = args;
     this._instArgs = instArgs;
     this._methodSignature = methodSignature;
     if (callContext == null)
     {
         this._logicalCallContext = new System.Runtime.Remoting.Messaging.LogicalCallContext();
     }
     else
     {
         this._logicalCallContext = callContext;
     }
     this._properties = properties;
 }
开发者ID:pritesh-mandowara-sp,项目名称:DecompliedDotNetLibraries,代码行数:22,代码来源:BinaryMethodCallMessage.cs


示例20: Reader

 public Reader(LogicalCallContext ctx) { m_ctx = ctx; }
开发者ID:krytht,项目名称:DotNetReferenceSource,代码行数:1,代码来源:CallContext.cs



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
C# Messaging.ReturnMessage类代码示例发布时间:2022-05-26
下一篇:
C# Messaging.Header类代码示例发布时间:2022-05-26
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

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

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

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