当前位置: 首页>>代码示例>>C#>>正文


C# Messaging.LogicalCallContext类代码示例

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


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


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