MarshalProperties() static private method

static private MarshalProperties ( IDictionary dict, ArrayList &args ) : int
dict IDictionary
args System.Collections.ArrayList
return int
コード例 #1
0
        internal CADMethodCallMessage(IMethodCallMessage callMsg)
        {
            this._uri         = callMsg.Uri;
            this.MethodHandle = callMsg.MethodBase.MethodHandle;
            this.FullTypeName = callMsg.MethodBase.DeclaringType.AssemblyQualifiedName;
            ArrayList arrayList = null;

            this._propertyCount = CADMessageBase.MarshalProperties(callMsg.Properties, ref arrayList);
            this._args          = base.MarshalArguments(callMsg.Args, ref arrayList);
            base.SaveLogicalCallContext(callMsg, ref arrayList);
            if (arrayList != null)
            {
                MemoryStream memoryStream = CADSerializer.SerializeObject(arrayList.ToArray());
                this._serializedArgs = memoryStream.GetBuffer();
            }
        }
コード例 #2
0
        internal CADMethodReturnMessage(IMethodReturnMessage retMsg)
        {
            ArrayList arrayList = null;

            this._propertyCount = CADMessageBase.MarshalProperties(retMsg.Properties, ref arrayList);
            this._returnValue   = base.MarshalArgument(retMsg.ReturnValue, ref arrayList);
            this._args          = base.MarshalArguments(retMsg.Args, ref arrayList);
            if (retMsg.Exception != null)
            {
                if (arrayList == null)
                {
                    arrayList = new ArrayList();
                }
                this._exception = new CADArgHolder(arrayList.Count);
                arrayList.Add(retMsg.Exception);
            }
            base.SaveLogicalCallContext(retMsg, ref arrayList);
            if (arrayList != null)
            {
                MemoryStream memoryStream = CADSerializer.SerializeObject(arrayList.ToArray());
                this._serializedArgs = memoryStream.GetBuffer();
            }
        }