scripts
This commit is contained in:
@@ -0,0 +1,76 @@
|
||||
using System;
|
||||
using System.Reflection;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003D7 RID: 983
|
||||
internal class ArgInfo
|
||||
{
|
||||
// Token: 0x06002692 RID: 9874 RVA: 0x0007EFF8 File Offset: 0x0007D1F8
|
||||
public ArgInfo(MethodBase method, ArgInfoType type)
|
||||
{
|
||||
this._method = method;
|
||||
ParameterInfo[] parameters = this._method.GetParameters();
|
||||
this._paramMap = new int[parameters.Length];
|
||||
this._inoutArgCount = 0;
|
||||
if (type == ArgInfoType.In)
|
||||
{
|
||||
for (int i = 0; i < parameters.Length; i++)
|
||||
{
|
||||
if (!parameters[i].ParameterType.IsByRef)
|
||||
{
|
||||
this._paramMap[this._inoutArgCount++] = i;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
for (int j = 0; j < parameters.Length; j++)
|
||||
{
|
||||
if (parameters[j].ParameterType.IsByRef || parameters[j].IsOut)
|
||||
{
|
||||
this._paramMap[this._inoutArgCount++] = j;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002693 RID: 9875 RVA: 0x0007F0CC File Offset: 0x0007D2CC
|
||||
public int GetInOutArgIndex(int inoutArgNum)
|
||||
{
|
||||
return this._paramMap[inoutArgNum];
|
||||
}
|
||||
|
||||
// Token: 0x06002694 RID: 9876 RVA: 0x0007F0D8 File Offset: 0x0007D2D8
|
||||
public virtual string GetInOutArgName(int index)
|
||||
{
|
||||
return this._method.GetParameters()[this._paramMap[index]].Name;
|
||||
}
|
||||
|
||||
// Token: 0x06002695 RID: 9877 RVA: 0x0007F0F4 File Offset: 0x0007D2F4
|
||||
public int GetInOutArgCount()
|
||||
{
|
||||
return this._inoutArgCount;
|
||||
}
|
||||
|
||||
// Token: 0x06002696 RID: 9878 RVA: 0x0007F0FC File Offset: 0x0007D2FC
|
||||
public object[] GetInOutArgs(object[] args)
|
||||
{
|
||||
object[] array = new object[this._inoutArgCount];
|
||||
for (int i = 0; i < this._inoutArgCount; i++)
|
||||
{
|
||||
array[i] = args[this._paramMap[i]];
|
||||
}
|
||||
return array;
|
||||
}
|
||||
|
||||
// Token: 0x04000F0E RID: 3854
|
||||
private int[] _paramMap;
|
||||
|
||||
// Token: 0x04000F0F RID: 3855
|
||||
private int _inoutArgCount;
|
||||
|
||||
// Token: 0x04000F10 RID: 3856
|
||||
private MethodBase _method;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
using System;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003D6 RID: 982
|
||||
internal enum ArgInfoType : byte
|
||||
{
|
||||
// Token: 0x04000F0C RID: 3852
|
||||
In,
|
||||
// Token: 0x04000F0D RID: 3853
|
||||
Out
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,244 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Threading;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Encapsulates the results of an asynchronous operation on a delegate.</summary>
|
||||
// Token: 0x020003D8 RID: 984
|
||||
[ComVisible(true)]
|
||||
public class AsyncResult : IAsyncResult, IMessageSink
|
||||
{
|
||||
// Token: 0x06002697 RID: 9879 RVA: 0x0007F13C File Offset: 0x0007D33C
|
||||
internal AsyncResult()
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>Gets the object provided as the last parameter of a BeginInvoke method call.</summary>
|
||||
/// <returns>The object provided as the last parameter of a BeginInvoke method call.</returns>
|
||||
// Token: 0x1700073A RID: 1850
|
||||
// (get) Token: 0x06002698 RID: 9880 RVA: 0x0007F144 File Offset: 0x0007D344
|
||||
public virtual object AsyncState
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.async_state;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a <see cref="T:System.Threading.WaitHandle" /> that encapsulates Win32 synchronization handles, and allows the implementation of various synchronization schemes.</summary>
|
||||
/// <returns>A <see cref="T:System.Threading.WaitHandle" /> that encapsulates Win32 synchronization handles, and allows the implementation of various synchronization schemes.</returns>
|
||||
// Token: 0x1700073B RID: 1851
|
||||
// (get) Token: 0x06002699 RID: 9881 RVA: 0x0007F14C File Offset: 0x0007D34C
|
||||
public virtual WaitHandle AsyncWaitHandle
|
||||
{
|
||||
get
|
||||
{
|
||||
WaitHandle waitHandle;
|
||||
lock (this)
|
||||
{
|
||||
if (this.handle == null)
|
||||
{
|
||||
this.handle = new ManualResetEvent(this.completed);
|
||||
}
|
||||
waitHandle = this.handle;
|
||||
}
|
||||
return waitHandle;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a value indicating whether the BeginInvoke call completed synchronously.</summary>
|
||||
/// <returns>true if the BeginInvoke call completed synchronously; otherwise, false.</returns>
|
||||
// Token: 0x1700073C RID: 1852
|
||||
// (get) Token: 0x0600269A RID: 9882 RVA: 0x0007F1B4 File Offset: 0x0007D3B4
|
||||
public virtual bool CompletedSynchronously
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.sync_completed;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a value indicating whether the server has completed the call.</summary>
|
||||
/// <returns>true after the server has completed the call; otherwise, false.</returns>
|
||||
// Token: 0x1700073D RID: 1853
|
||||
// (get) Token: 0x0600269B RID: 9883 RVA: 0x0007F1BC File Offset: 0x0007D3BC
|
||||
public virtual bool IsCompleted
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.completed;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets or sets a value indicating whether EndInvoke has been called on the current <see cref="T:System.Runtime.Remoting.Messaging.AsyncResult" />.</summary>
|
||||
/// <returns>true if EndInvoke has been called on the current <see cref="T:System.Runtime.Remoting.Messaging.AsyncResult" />; otherwise, false.</returns>
|
||||
// Token: 0x1700073E RID: 1854
|
||||
// (get) Token: 0x0600269C RID: 9884 RVA: 0x0007F1C4 File Offset: 0x0007D3C4
|
||||
// (set) Token: 0x0600269D RID: 9885 RVA: 0x0007F1CC File Offset: 0x0007D3CC
|
||||
public bool EndInvokeCalled
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.endinvoke_called;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.endinvoke_called = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the delegate object on which the asynchronous call was invoked.</summary>
|
||||
/// <returns>The delegate object on which the asynchronous call was invoked.</returns>
|
||||
// Token: 0x1700073F RID: 1855
|
||||
// (get) Token: 0x0600269E RID: 9886 RVA: 0x0007F1D8 File Offset: 0x0007D3D8
|
||||
public virtual object AsyncDelegate
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.async_delegate;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the next message sink in the sink chain.</summary>
|
||||
/// <returns>An <see cref="T:System.Runtime.Remoting.Messaging.IMessageSink" /> interface that represents the next message sink in the sink chain.</returns>
|
||||
// Token: 0x17000740 RID: 1856
|
||||
// (get) Token: 0x0600269F RID: 9887 RVA: 0x0007F1E0 File Offset: 0x0007D3E0
|
||||
public IMessageSink NextSink
|
||||
{
|
||||
get
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Implements the <see cref="T:System.Runtime.Remoting.Messaging.IMessageSink" /> interface.</summary>
|
||||
/// <returns>No value is returned.</returns>
|
||||
/// <param name="msg">The request <see cref="T:System.Runtime.Remoting.Messaging.IMessage" /> interface. </param>
|
||||
/// <param name="replySink">The response <see cref="T:System.Runtime.Remoting.Messaging.IMessageSink" /> interface. </param>
|
||||
// Token: 0x060026A0 RID: 9888 RVA: 0x0007F1E4 File Offset: 0x0007D3E4
|
||||
public virtual IMessageCtrl AsyncProcessMessage(IMessage msg, IMessageSink replySink)
|
||||
{
|
||||
throw new NotSupportedException();
|
||||
}
|
||||
|
||||
/// <summary>Gets the response message for the asynchronous call.</summary>
|
||||
/// <returns>A remoting message that should represent a response to a method call on a remote object.</returns>
|
||||
// Token: 0x060026A1 RID: 9889 RVA: 0x0007F1EC File Offset: 0x0007D3EC
|
||||
public virtual IMessage GetReplyMessage()
|
||||
{
|
||||
return this.reply_message;
|
||||
}
|
||||
|
||||
/// <summary>Sets an <see cref="T:System.Runtime.Remoting.Messaging.IMessageCtrl" /> for the current remote method call, which provides a way to control asynchronous messages after they have been dispatched.</summary>
|
||||
/// <param name="mc">The <see cref="T:System.Runtime.Remoting.Messaging.IMessageCtrl" /> for the current remote method call. </param>
|
||||
// Token: 0x060026A2 RID: 9890 RVA: 0x0007F1F4 File Offset: 0x0007D3F4
|
||||
public virtual void SetMessageCtrl(IMessageCtrl mc)
|
||||
{
|
||||
this.message_ctrl = mc;
|
||||
}
|
||||
|
||||
// Token: 0x060026A3 RID: 9891 RVA: 0x0007F200 File Offset: 0x0007D400
|
||||
internal void SetCompletedSynchronously(bool completed)
|
||||
{
|
||||
this.sync_completed = completed;
|
||||
}
|
||||
|
||||
// Token: 0x060026A4 RID: 9892 RVA: 0x0007F20C File Offset: 0x0007D40C
|
||||
internal IMessage EndInvoke()
|
||||
{
|
||||
lock (this)
|
||||
{
|
||||
if (this.completed)
|
||||
{
|
||||
return this.reply_message;
|
||||
}
|
||||
}
|
||||
this.AsyncWaitHandle.WaitOne();
|
||||
return this.reply_message;
|
||||
}
|
||||
|
||||
/// <summary>Synchronously processes a response message returned by a method call on a remote object.</summary>
|
||||
/// <returns>Returns null.</returns>
|
||||
/// <param name="msg">A response message to a method call on a remote object.</param>
|
||||
// Token: 0x060026A5 RID: 9893 RVA: 0x0007F274 File Offset: 0x0007D474
|
||||
public virtual IMessage SyncProcessMessage(IMessage msg)
|
||||
{
|
||||
this.reply_message = msg;
|
||||
lock (this)
|
||||
{
|
||||
this.completed = true;
|
||||
if (this.handle != null)
|
||||
{
|
||||
((ManualResetEvent)this.AsyncWaitHandle).Set();
|
||||
}
|
||||
}
|
||||
if (this.async_callback != null)
|
||||
{
|
||||
AsyncCallback asyncCallback = (AsyncCallback)this.async_callback;
|
||||
asyncCallback(this);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
// Token: 0x17000741 RID: 1857
|
||||
// (get) Token: 0x060026A6 RID: 9894 RVA: 0x0007F2FC File Offset: 0x0007D4FC
|
||||
// (set) Token: 0x060026A7 RID: 9895 RVA: 0x0007F304 File Offset: 0x0007D504
|
||||
internal MonoMethodMessage CallMessage
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.call_message;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.call_message = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F11 RID: 3857
|
||||
private object async_state;
|
||||
|
||||
// Token: 0x04000F12 RID: 3858
|
||||
private WaitHandle handle;
|
||||
|
||||
// Token: 0x04000F13 RID: 3859
|
||||
private object async_delegate;
|
||||
|
||||
// Token: 0x04000F14 RID: 3860
|
||||
private IntPtr data;
|
||||
|
||||
// Token: 0x04000F15 RID: 3861
|
||||
private object object_data;
|
||||
|
||||
// Token: 0x04000F16 RID: 3862
|
||||
private bool sync_completed;
|
||||
|
||||
// Token: 0x04000F17 RID: 3863
|
||||
private bool completed;
|
||||
|
||||
// Token: 0x04000F18 RID: 3864
|
||||
private bool endinvoke_called;
|
||||
|
||||
// Token: 0x04000F19 RID: 3865
|
||||
private object async_callback;
|
||||
|
||||
// Token: 0x04000F1A RID: 3866
|
||||
private ExecutionContext current;
|
||||
|
||||
// Token: 0x04000F1B RID: 3867
|
||||
private ExecutionContext original;
|
||||
|
||||
// Token: 0x04000F1C RID: 3868
|
||||
private int gchandle;
|
||||
|
||||
// Token: 0x04000F1D RID: 3869
|
||||
private MonoMethodMessage call_message;
|
||||
|
||||
// Token: 0x04000F1E RID: 3870
|
||||
private IMessageCtrl message_ctrl;
|
||||
|
||||
// Token: 0x04000F1F RID: 3871
|
||||
private IMessage reply_message;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003D9 RID: 985
|
||||
internal class CADArgHolder
|
||||
{
|
||||
// Token: 0x060026A8 RID: 9896 RVA: 0x0007F310 File Offset: 0x0007D510
|
||||
public CADArgHolder(int i)
|
||||
{
|
||||
this.index = i;
|
||||
}
|
||||
|
||||
// Token: 0x04000F20 RID: 3872
|
||||
public int index;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,274 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.Remoting.Channels;
|
||||
using System.Threading;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003DB RID: 987
|
||||
internal class CADMessageBase
|
||||
{
|
||||
// Token: 0x060026AD RID: 9901 RVA: 0x0007F364 File Offset: 0x0007D564
|
||||
internal static int MarshalProperties(IDictionary dict, ref ArrayList args)
|
||||
{
|
||||
int num = 0;
|
||||
MethodDictionary methodDictionary = dict as MethodDictionary;
|
||||
if (methodDictionary != null)
|
||||
{
|
||||
if (methodDictionary.HasInternalProperties)
|
||||
{
|
||||
IDictionary internalProperties = methodDictionary.InternalProperties;
|
||||
if (internalProperties != null)
|
||||
{
|
||||
foreach (object obj in internalProperties)
|
||||
{
|
||||
DictionaryEntry dictionaryEntry = (DictionaryEntry)obj;
|
||||
if (args == null)
|
||||
{
|
||||
args = new ArrayList();
|
||||
}
|
||||
args.Add(dictionaryEntry);
|
||||
num++;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (dict != null)
|
||||
{
|
||||
foreach (object obj2 in dict)
|
||||
{
|
||||
DictionaryEntry dictionaryEntry2 = (DictionaryEntry)obj2;
|
||||
if (args == null)
|
||||
{
|
||||
args = new ArrayList();
|
||||
}
|
||||
args.Add(dictionaryEntry2);
|
||||
num++;
|
||||
}
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
// Token: 0x060026AE RID: 9902 RVA: 0x0007F4A0 File Offset: 0x0007D6A0
|
||||
internal static void UnmarshalProperties(IDictionary dict, int count, ArrayList args)
|
||||
{
|
||||
for (int i = 0; i < count; i++)
|
||||
{
|
||||
DictionaryEntry dictionaryEntry = (DictionaryEntry)args[i];
|
||||
dict[dictionaryEntry.Key] = dictionaryEntry.Value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060026AF RID: 9903 RVA: 0x0007F4E0 File Offset: 0x0007D6E0
|
||||
private static bool IsPossibleToIgnoreMarshal(object obj)
|
||||
{
|
||||
Type type = obj.GetType();
|
||||
return type.IsPrimitive || type == typeof(void) || (type.IsArray && type.GetElementType().IsPrimitive && ((Array)obj).Rank == 1) || (obj is string || obj is DateTime || obj is TimeSpan);
|
||||
}
|
||||
|
||||
// Token: 0x060026B0 RID: 9904 RVA: 0x0007F564 File Offset: 0x0007D764
|
||||
protected object MarshalArgument(object arg, ref ArrayList args)
|
||||
{
|
||||
if (arg == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
if (CADMessageBase.IsPossibleToIgnoreMarshal(arg))
|
||||
{
|
||||
return arg;
|
||||
}
|
||||
MarshalByRefObject marshalByRefObject = arg as MarshalByRefObject;
|
||||
if (marshalByRefObject != null)
|
||||
{
|
||||
if (!RemotingServices.IsTransparentProxy(marshalByRefObject))
|
||||
{
|
||||
ObjRef objRef = RemotingServices.Marshal(marshalByRefObject);
|
||||
return new CADObjRef(objRef, Thread.GetDomainID());
|
||||
}
|
||||
}
|
||||
if (args == null)
|
||||
{
|
||||
args = new ArrayList();
|
||||
}
|
||||
args.Add(arg);
|
||||
return new CADArgHolder(args.Count - 1);
|
||||
}
|
||||
|
||||
// Token: 0x060026B1 RID: 9905 RVA: 0x0007F5DC File Offset: 0x0007D7DC
|
||||
protected object UnmarshalArgument(object arg, ArrayList args)
|
||||
{
|
||||
if (arg == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
CADArgHolder cadargHolder = arg as CADArgHolder;
|
||||
if (cadargHolder != null)
|
||||
{
|
||||
return args[cadargHolder.index];
|
||||
}
|
||||
CADObjRef cadobjRef = arg as CADObjRef;
|
||||
if (cadobjRef != null)
|
||||
{
|
||||
string text = string.Copy(cadobjRef.TypeName);
|
||||
string text2 = string.Copy(cadobjRef.URI);
|
||||
int sourceDomain = cadobjRef.SourceDomain;
|
||||
ChannelInfo channelInfo = new ChannelInfo(new CrossAppDomainData(sourceDomain));
|
||||
ObjRef objRef = new ObjRef(text, text2, channelInfo);
|
||||
return RemotingServices.Unmarshal(objRef);
|
||||
}
|
||||
if (arg is Array)
|
||||
{
|
||||
Array array = (Array)arg;
|
||||
Array array2;
|
||||
switch (Type.GetTypeCode(arg.GetType().GetElementType()))
|
||||
{
|
||||
case TypeCode.Boolean:
|
||||
array2 = new bool[array.Length];
|
||||
break;
|
||||
case TypeCode.Char:
|
||||
array2 = new char[array.Length];
|
||||
break;
|
||||
case TypeCode.SByte:
|
||||
array2 = new sbyte[array.Length];
|
||||
break;
|
||||
case TypeCode.Byte:
|
||||
array2 = new byte[array.Length];
|
||||
break;
|
||||
case TypeCode.Int16:
|
||||
array2 = new short[array.Length];
|
||||
break;
|
||||
case TypeCode.UInt16:
|
||||
array2 = new ushort[array.Length];
|
||||
break;
|
||||
case TypeCode.Int32:
|
||||
array2 = new int[array.Length];
|
||||
break;
|
||||
case TypeCode.UInt32:
|
||||
array2 = new uint[array.Length];
|
||||
break;
|
||||
case TypeCode.Int64:
|
||||
array2 = new long[array.Length];
|
||||
break;
|
||||
case TypeCode.UInt64:
|
||||
array2 = new ulong[array.Length];
|
||||
break;
|
||||
case TypeCode.Single:
|
||||
array2 = new float[array.Length];
|
||||
break;
|
||||
case TypeCode.Double:
|
||||
array2 = new double[array.Length];
|
||||
break;
|
||||
case TypeCode.Decimal:
|
||||
array2 = new decimal[array.Length];
|
||||
break;
|
||||
default:
|
||||
throw new NotSupportedException();
|
||||
}
|
||||
array.CopyTo(array2, 0);
|
||||
return array2;
|
||||
}
|
||||
switch (Type.GetTypeCode(arg.GetType()))
|
||||
{
|
||||
case TypeCode.Boolean:
|
||||
return (bool)arg;
|
||||
case TypeCode.Char:
|
||||
return (char)arg;
|
||||
case TypeCode.SByte:
|
||||
return (sbyte)arg;
|
||||
case TypeCode.Byte:
|
||||
return (byte)arg;
|
||||
case TypeCode.Int16:
|
||||
return (short)arg;
|
||||
case TypeCode.UInt16:
|
||||
return (ushort)arg;
|
||||
case TypeCode.Int32:
|
||||
return (int)arg;
|
||||
case TypeCode.UInt32:
|
||||
return (uint)arg;
|
||||
case TypeCode.Int64:
|
||||
return (long)arg;
|
||||
case TypeCode.UInt64:
|
||||
return (ulong)arg;
|
||||
case TypeCode.Single:
|
||||
return (float)arg;
|
||||
case TypeCode.Double:
|
||||
return (double)arg;
|
||||
case TypeCode.Decimal:
|
||||
return (decimal)arg;
|
||||
case TypeCode.DateTime:
|
||||
return new DateTime(((DateTime)arg).Ticks);
|
||||
case TypeCode.String:
|
||||
return string.Copy((string)arg);
|
||||
}
|
||||
if (arg is TimeSpan)
|
||||
{
|
||||
return new TimeSpan(((TimeSpan)arg).Ticks);
|
||||
}
|
||||
if (arg is IntPtr)
|
||||
{
|
||||
return (IntPtr)arg;
|
||||
}
|
||||
throw new NotSupportedException("Parameter of type " + arg.GetType() + " cannot be unmarshalled");
|
||||
}
|
||||
|
||||
// Token: 0x060026B2 RID: 9906 RVA: 0x0007F944 File Offset: 0x0007DB44
|
||||
internal object[] MarshalArguments(object[] arguments, ref ArrayList args)
|
||||
{
|
||||
object[] array = new object[arguments.Length];
|
||||
int num = arguments.Length;
|
||||
for (int i = 0; i < num; i++)
|
||||
{
|
||||
array[i] = this.MarshalArgument(arguments[i], ref args);
|
||||
}
|
||||
return array;
|
||||
}
|
||||
|
||||
// Token: 0x060026B3 RID: 9907 RVA: 0x0007F980 File Offset: 0x0007DB80
|
||||
internal object[] UnmarshalArguments(object[] arguments, ArrayList args)
|
||||
{
|
||||
object[] array = new object[arguments.Length];
|
||||
int num = arguments.Length;
|
||||
for (int i = 0; i < num; i++)
|
||||
{
|
||||
array[i] = this.UnmarshalArgument(arguments[i], args);
|
||||
}
|
||||
return array;
|
||||
}
|
||||
|
||||
// Token: 0x060026B4 RID: 9908 RVA: 0x0007F9BC File Offset: 0x0007DBBC
|
||||
protected void SaveLogicalCallContext(IMethodMessage msg, ref ArrayList serializeList)
|
||||
{
|
||||
if (msg.LogicalCallContext != null && msg.LogicalCallContext.HasInfo)
|
||||
{
|
||||
if (serializeList == null)
|
||||
{
|
||||
serializeList = new ArrayList();
|
||||
}
|
||||
this._callContext = new CADArgHolder(serializeList.Count);
|
||||
serializeList.Add(msg.LogicalCallContext);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060026B5 RID: 9909 RVA: 0x0007FA14 File Offset: 0x0007DC14
|
||||
internal LogicalCallContext GetLogicalCallContext(ArrayList args)
|
||||
{
|
||||
if (this._callContext == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return (LogicalCallContext)args[this._callContext.index];
|
||||
}
|
||||
|
||||
// Token: 0x04000F23 RID: 3875
|
||||
protected object[] _args;
|
||||
|
||||
// Token: 0x04000F24 RID: 3876
|
||||
protected byte[] _serializedArgs;
|
||||
|
||||
// Token: 0x04000F25 RID: 3877
|
||||
protected int _propertyCount;
|
||||
|
||||
// Token: 0x04000F26 RID: 3878
|
||||
protected CADArgHolder _callContext;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,167 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.IO;
|
||||
using System.Reflection;
|
||||
using System.Runtime.Remoting.Channels;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003DC RID: 988
|
||||
internal class CADMethodCallMessage : CADMessageBase
|
||||
{
|
||||
// Token: 0x060026B6 RID: 9910 RVA: 0x0007FA3C File Offset: 0x0007DC3C
|
||||
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();
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000744 RID: 1860
|
||||
// (get) Token: 0x060026B7 RID: 9911 RVA: 0x0007FAD4 File Offset: 0x0007DCD4
|
||||
internal string Uri
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._uri;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060026B8 RID: 9912 RVA: 0x0007FADC File Offset: 0x0007DCDC
|
||||
internal static CADMethodCallMessage Create(IMessage callMsg)
|
||||
{
|
||||
IMethodCallMessage methodCallMessage = callMsg as IMethodCallMessage;
|
||||
if (methodCallMessage == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return new CADMethodCallMessage(methodCallMessage);
|
||||
}
|
||||
|
||||
// Token: 0x060026B9 RID: 9913 RVA: 0x0007FB00 File Offset: 0x0007DD00
|
||||
internal ArrayList GetArguments()
|
||||
{
|
||||
ArrayList arrayList = null;
|
||||
if (this._serializedArgs != null)
|
||||
{
|
||||
object[] array = (object[])CADSerializer.DeserializeObject(new MemoryStream(this._serializedArgs));
|
||||
arrayList = new ArrayList(array);
|
||||
this._serializedArgs = null;
|
||||
}
|
||||
return arrayList;
|
||||
}
|
||||
|
||||
// Token: 0x060026BA RID: 9914 RVA: 0x0007FB40 File Offset: 0x0007DD40
|
||||
internal object[] GetArgs(ArrayList args)
|
||||
{
|
||||
return base.UnmarshalArguments(this._args, args);
|
||||
}
|
||||
|
||||
// Token: 0x17000745 RID: 1861
|
||||
// (get) Token: 0x060026BB RID: 9915 RVA: 0x0007FB50 File Offset: 0x0007DD50
|
||||
internal int PropertiesCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._propertyCount;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060026BC RID: 9916 RVA: 0x0007FB58 File Offset: 0x0007DD58
|
||||
private static Type[] GetSignature(MethodBase methodBase, bool load)
|
||||
{
|
||||
ParameterInfo[] parameters = methodBase.GetParameters();
|
||||
Type[] array = new Type[parameters.Length];
|
||||
for (int i = 0; i < parameters.Length; i++)
|
||||
{
|
||||
if (load)
|
||||
{
|
||||
array[i] = Type.GetType(parameters[i].ParameterType.AssemblyQualifiedName, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
array[i] = parameters[i].ParameterType;
|
||||
}
|
||||
}
|
||||
return array;
|
||||
}
|
||||
|
||||
// Token: 0x060026BD RID: 9917 RVA: 0x0007FBB8 File Offset: 0x0007DDB8
|
||||
internal MethodBase GetMethod()
|
||||
{
|
||||
Type type = Type.GetType(this.FullTypeName);
|
||||
MethodBase methodBase;
|
||||
if (type.IsGenericType || type.IsGenericTypeDefinition)
|
||||
{
|
||||
methodBase = MethodBase.GetMethodFromHandleNoGenericCheck(this.MethodHandle);
|
||||
}
|
||||
else
|
||||
{
|
||||
methodBase = MethodBase.GetMethodFromHandle(this.MethodHandle);
|
||||
}
|
||||
if (type == methodBase.DeclaringType)
|
||||
{
|
||||
return methodBase;
|
||||
}
|
||||
Type[] signature = CADMethodCallMessage.GetSignature(methodBase, true);
|
||||
if (methodBase.IsGenericMethod)
|
||||
{
|
||||
MethodBase[] methods = type.GetMethods(BindingFlags.Instance | BindingFlags.Public | BindingFlags.NonPublic);
|
||||
Type[] genericArguments = methodBase.GetGenericArguments();
|
||||
foreach (MethodBase methodBase2 in methods)
|
||||
{
|
||||
if (methodBase2.IsGenericMethod && !(methodBase2.Name != methodBase.Name))
|
||||
{
|
||||
Type[] genericArguments2 = methodBase2.GetGenericArguments();
|
||||
if (genericArguments.Length == genericArguments2.Length)
|
||||
{
|
||||
MethodInfo methodInfo = ((MethodInfo)methodBase2).MakeGenericMethod(genericArguments);
|
||||
Type[] signature2 = CADMethodCallMessage.GetSignature(methodInfo, false);
|
||||
if (signature2.Length == signature.Length)
|
||||
{
|
||||
bool flag = false;
|
||||
for (int j = signature2.Length - 1; j >= 0; j--)
|
||||
{
|
||||
if (signature2[j] != signature[j])
|
||||
{
|
||||
flag = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (!flag)
|
||||
{
|
||||
return methodInfo;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return methodBase;
|
||||
}
|
||||
MethodBase method = type.GetMethod(methodBase.Name, BindingFlags.Instance | BindingFlags.Public | BindingFlags.NonPublic, null, signature, null);
|
||||
if (method == null)
|
||||
{
|
||||
throw new RemotingException(string.Concat(new object[] { "Method '", methodBase.Name, "' not found in type '", type, "'" }));
|
||||
}
|
||||
return method;
|
||||
}
|
||||
|
||||
// Token: 0x04000F27 RID: 3879
|
||||
private string _uri;
|
||||
|
||||
// Token: 0x04000F28 RID: 3880
|
||||
internal RuntimeMethodHandle MethodHandle;
|
||||
|
||||
// Token: 0x04000F29 RID: 3881
|
||||
internal string FullTypeName;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,97 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.IO;
|
||||
using System.Runtime.Remoting.Channels;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003DD RID: 989
|
||||
internal class CADMethodReturnMessage : CADMessageBase
|
||||
{
|
||||
// Token: 0x060026BE RID: 9918 RVA: 0x0007FD60 File Offset: 0x0007DF60
|
||||
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();
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060026BF RID: 9919 RVA: 0x0007FE0C File Offset: 0x0007E00C
|
||||
internal static CADMethodReturnMessage Create(IMessage callMsg)
|
||||
{
|
||||
IMethodReturnMessage methodReturnMessage = callMsg as IMethodReturnMessage;
|
||||
if (methodReturnMessage == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return new CADMethodReturnMessage(methodReturnMessage);
|
||||
}
|
||||
|
||||
// Token: 0x060026C0 RID: 9920 RVA: 0x0007FE30 File Offset: 0x0007E030
|
||||
internal ArrayList GetArguments()
|
||||
{
|
||||
ArrayList arrayList = null;
|
||||
if (this._serializedArgs != null)
|
||||
{
|
||||
object[] array = (object[])CADSerializer.DeserializeObject(new MemoryStream(this._serializedArgs));
|
||||
arrayList = new ArrayList(array);
|
||||
this._serializedArgs = null;
|
||||
}
|
||||
return arrayList;
|
||||
}
|
||||
|
||||
// Token: 0x060026C1 RID: 9921 RVA: 0x0007FE70 File Offset: 0x0007E070
|
||||
internal object[] GetArgs(ArrayList args)
|
||||
{
|
||||
return base.UnmarshalArguments(this._args, args);
|
||||
}
|
||||
|
||||
// Token: 0x060026C2 RID: 9922 RVA: 0x0007FE80 File Offset: 0x0007E080
|
||||
internal object GetReturnValue(ArrayList args)
|
||||
{
|
||||
return base.UnmarshalArgument(this._returnValue, args);
|
||||
}
|
||||
|
||||
// Token: 0x060026C3 RID: 9923 RVA: 0x0007FE90 File Offset: 0x0007E090
|
||||
internal Exception GetException(ArrayList args)
|
||||
{
|
||||
if (this._exception == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return (Exception)args[this._exception.index];
|
||||
}
|
||||
|
||||
// Token: 0x17000746 RID: 1862
|
||||
// (get) Token: 0x060026C4 RID: 9924 RVA: 0x0007FEB8 File Offset: 0x0007E0B8
|
||||
internal int PropertiesCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._propertyCount;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F2A RID: 3882
|
||||
private object _returnValue;
|
||||
|
||||
// Token: 0x04000F2B RID: 3883
|
||||
private CADArgHolder _exception;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
using System;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003DA RID: 986
|
||||
internal class CADObjRef
|
||||
{
|
||||
// Token: 0x060026A9 RID: 9897 RVA: 0x0007F320 File Offset: 0x0007D520
|
||||
public CADObjRef(ObjRef o, int sourceDomain)
|
||||
{
|
||||
this.objref = o;
|
||||
this.SourceDomain = sourceDomain;
|
||||
}
|
||||
|
||||
// Token: 0x17000742 RID: 1858
|
||||
// (get) Token: 0x060026AA RID: 9898 RVA: 0x0007F338 File Offset: 0x0007D538
|
||||
public string TypeName
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.objref.TypeInfo.TypeName;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000743 RID: 1859
|
||||
// (get) Token: 0x060026AB RID: 9899 RVA: 0x0007F34C File Offset: 0x0007D54C
|
||||
public string URI
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.objref.URI;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F21 RID: 3873
|
||||
private ObjRef objref;
|
||||
|
||||
// Token: 0x04000F22 RID: 3874
|
||||
public int SourceDomain;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,201 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Provides a set of properties that are carried with the execution code path. This class cannot be inherited.</summary>
|
||||
// Token: 0x020003DE RID: 990
|
||||
[ComVisible(true)]
|
||||
[Serializable]
|
||||
public sealed class CallContext
|
||||
{
|
||||
// Token: 0x060026C5 RID: 9925 RVA: 0x0007FEC0 File Offset: 0x0007E0C0
|
||||
private CallContext()
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>Gets or sets the host context associated with the current thread.</summary>
|
||||
/// <returns>The host context associated with the current thread.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller does not have infrastructure permission. </exception>
|
||||
// Token: 0x17000747 RID: 1863
|
||||
// (get) Token: 0x060026C6 RID: 9926 RVA: 0x0007FEC8 File Offset: 0x0007E0C8
|
||||
// (set) Token: 0x060026C7 RID: 9927 RVA: 0x0007FED0 File Offset: 0x0007E0D0
|
||||
public static object HostContext
|
||||
{
|
||||
get
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
set
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Empties a data slot with the specified name.</summary>
|
||||
/// <param name="name">The name of the data slot to empty. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060026C8 RID: 9928 RVA: 0x0007FED8 File Offset: 0x0007E0D8
|
||||
public static void FreeNamedDataSlot(string name)
|
||||
{
|
||||
CallContext.Datastore.Remove(name);
|
||||
}
|
||||
|
||||
/// <summary>Retrieves an object with the specified name from the <see cref="T:System.Runtime.Remoting.Messaging.CallContext" />.</summary>
|
||||
/// <returns>The object in the call context associated with the specified name.</returns>
|
||||
/// <param name="name">The name of the item in the call context. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060026C9 RID: 9929 RVA: 0x0007FEE8 File Offset: 0x0007E0E8
|
||||
public static object GetData(string name)
|
||||
{
|
||||
return CallContext.Datastore[name];
|
||||
}
|
||||
|
||||
/// <summary>Stores a given object and associates it with the specified name.</summary>
|
||||
/// <param name="name">The name with which to associate the new item in the call context. </param>
|
||||
/// <param name="data">The object to store in the call context. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060026CA RID: 9930 RVA: 0x0007FEF8 File Offset: 0x0007E0F8
|
||||
public static void SetData(string name, object data)
|
||||
{
|
||||
CallContext.Datastore[name] = data;
|
||||
}
|
||||
|
||||
/// <summary>Retrieves an object with the specified name from the logical call context.</summary>
|
||||
/// <returns>The object in the logical call context associated with the specified name.</returns>
|
||||
/// <param name="name">The name of the item in the logical call context. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller does not have infrastructure permission. </exception>
|
||||
// Token: 0x060026CB RID: 9931 RVA: 0x0007FF08 File Offset: 0x0007E108
|
||||
[MonoTODO]
|
||||
public static object LogicalGetData(string name)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
/// <summary>Stores a given object in the logical call context and associates it with the specified name.</summary>
|
||||
/// <param name="name">The name with which to associate the new item in the logical call context. </param>
|
||||
/// <param name="data">The object to store in the logical call context. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller does not have infrastructure permission. </exception>
|
||||
// Token: 0x060026CC RID: 9932 RVA: 0x0007FF10 File Offset: 0x0007E110
|
||||
[MonoTODO]
|
||||
public static void LogicalSetData(string name, object data)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
/// <summary>Returns the headers that are sent along with the method call.</summary>
|
||||
/// <returns>The headers that are sent along with the method call.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060026CD RID: 9933 RVA: 0x0007FF18 File Offset: 0x0007E118
|
||||
public static Header[] GetHeaders()
|
||||
{
|
||||
return CallContext.Headers;
|
||||
}
|
||||
|
||||
/// <summary>Sets the headers that are sent along with the method call.</summary>
|
||||
/// <param name="headers">A <see cref="T:System.Runtime.Remoting.Messaging.Header" /> array of the headers that are to be sent along with the method call. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060026CE RID: 9934 RVA: 0x0007FF20 File Offset: 0x0007E120
|
||||
public static void SetHeaders(Header[] headers)
|
||||
{
|
||||
CallContext.Headers = headers;
|
||||
}
|
||||
|
||||
// Token: 0x060026CF RID: 9935 RVA: 0x0007FF28 File Offset: 0x0007E128
|
||||
internal static LogicalCallContext CreateLogicalCallContext(bool createEmpty)
|
||||
{
|
||||
LogicalCallContext logicalCallContext = null;
|
||||
if (CallContext.datastore != null)
|
||||
{
|
||||
foreach (object obj in CallContext.datastore)
|
||||
{
|
||||
DictionaryEntry dictionaryEntry = (DictionaryEntry)obj;
|
||||
if (dictionaryEntry.Value is ILogicalThreadAffinative)
|
||||
{
|
||||
if (logicalCallContext == null)
|
||||
{
|
||||
logicalCallContext = new LogicalCallContext();
|
||||
}
|
||||
logicalCallContext.SetData((string)dictionaryEntry.Key, dictionaryEntry.Value);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (logicalCallContext == null && createEmpty)
|
||||
{
|
||||
return new LogicalCallContext();
|
||||
}
|
||||
return logicalCallContext;
|
||||
}
|
||||
|
||||
// Token: 0x060026D0 RID: 9936 RVA: 0x0007FFE4 File Offset: 0x0007E1E4
|
||||
internal static object SetCurrentCallContext(LogicalCallContext ctx)
|
||||
{
|
||||
object obj = CallContext.datastore;
|
||||
if (ctx != null && ctx.HasInfo)
|
||||
{
|
||||
CallContext.datastore = (Hashtable)ctx.Datastore.Clone();
|
||||
}
|
||||
else
|
||||
{
|
||||
CallContext.datastore = null;
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
// Token: 0x060026D1 RID: 9937 RVA: 0x0008002C File Offset: 0x0007E22C
|
||||
internal static void UpdateCurrentCallContext(LogicalCallContext ctx)
|
||||
{
|
||||
Hashtable hashtable = ctx.Datastore;
|
||||
foreach (object obj in hashtable)
|
||||
{
|
||||
DictionaryEntry dictionaryEntry = (DictionaryEntry)obj;
|
||||
CallContext.SetData((string)dictionaryEntry.Key, dictionaryEntry.Value);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060026D2 RID: 9938 RVA: 0x000800B0 File Offset: 0x0007E2B0
|
||||
internal static void RestoreCallContext(object oldContext)
|
||||
{
|
||||
CallContext.datastore = (Hashtable)oldContext;
|
||||
}
|
||||
|
||||
// Token: 0x17000748 RID: 1864
|
||||
// (get) Token: 0x060026D3 RID: 9939 RVA: 0x000800C0 File Offset: 0x0007E2C0
|
||||
private static Hashtable Datastore
|
||||
{
|
||||
get
|
||||
{
|
||||
Hashtable hashtable = CallContext.datastore;
|
||||
if (hashtable == null)
|
||||
{
|
||||
return CallContext.datastore = new Hashtable();
|
||||
}
|
||||
return hashtable;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F2C RID: 3884
|
||||
[ThreadStatic]
|
||||
private static Header[] Headers;
|
||||
|
||||
// Token: 0x04000F2D RID: 3885
|
||||
[ThreadStatic]
|
||||
private static Hashtable datastore;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
using System;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003F3 RID: 1011
|
||||
[Serializable]
|
||||
internal class CallContextRemotingData : ICloneable
|
||||
{
|
||||
// Token: 0x17000776 RID: 1910
|
||||
// (get) Token: 0x0600273E RID: 10046 RVA: 0x00080AF8 File Offset: 0x0007ECF8
|
||||
// (set) Token: 0x0600273F RID: 10047 RVA: 0x00080B00 File Offset: 0x0007ED00
|
||||
public string LogicalCallID
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._logicalCallID;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._logicalCallID = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002740 RID: 10048 RVA: 0x00080B0C File Offset: 0x0007ED0C
|
||||
public object Clone()
|
||||
{
|
||||
return new CallContextRemotingData
|
||||
{
|
||||
_logicalCallID = this._logicalCallID
|
||||
};
|
||||
}
|
||||
|
||||
// Token: 0x04000F45 RID: 3909
|
||||
private string _logicalCallID;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003FF RID: 1023
|
||||
internal enum CallType
|
||||
{
|
||||
// Token: 0x04000F89 RID: 3977
|
||||
Sync,
|
||||
// Token: 0x04000F8A RID: 3978
|
||||
BeginInvoke,
|
||||
// Token: 0x04000F8B RID: 3979
|
||||
EndInvoke,
|
||||
// Token: 0x04000F8C RID: 3980
|
||||
OneWay
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
using System;
|
||||
using System.Runtime.Remoting.Contexts;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003E1 RID: 993
|
||||
internal class ClientContextReplySink : IMessageSink
|
||||
{
|
||||
// Token: 0x060026D8 RID: 9944 RVA: 0x00080210 File Offset: 0x0007E410
|
||||
public ClientContextReplySink(Context ctx, IMessageSink replySink)
|
||||
{
|
||||
this._replySink = replySink;
|
||||
this._context = ctx;
|
||||
}
|
||||
|
||||
// Token: 0x060026D9 RID: 9945 RVA: 0x00080228 File Offset: 0x0007E428
|
||||
public IMessage SyncProcessMessage(IMessage msg)
|
||||
{
|
||||
Context.NotifyGlobalDynamicSinks(false, msg, true, true);
|
||||
this._context.NotifyDynamicSinks(false, msg, true, true);
|
||||
return this._replySink.SyncProcessMessage(msg);
|
||||
}
|
||||
|
||||
// Token: 0x060026DA RID: 9946 RVA: 0x0008025C File Offset: 0x0007E45C
|
||||
public IMessageCtrl AsyncProcessMessage(IMessage msg, IMessageSink replySink)
|
||||
{
|
||||
throw new NotSupportedException();
|
||||
}
|
||||
|
||||
// Token: 0x1700074A RID: 1866
|
||||
// (get) Token: 0x060026DB RID: 9947 RVA: 0x00080264 File Offset: 0x0007E464
|
||||
public IMessageSink NextSink
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._replySink;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F2F RID: 3887
|
||||
private IMessageSink _replySink;
|
||||
|
||||
// Token: 0x04000F30 RID: 3888
|
||||
private Context _context;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,71 @@
|
||||
using System;
|
||||
using System.Runtime.Remoting.Activation;
|
||||
using System.Runtime.Remoting.Contexts;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003E0 RID: 992
|
||||
internal class ClientContextTerminatorSink : IMessageSink
|
||||
{
|
||||
// Token: 0x060026D4 RID: 9940 RVA: 0x000800E8 File Offset: 0x0007E2E8
|
||||
public ClientContextTerminatorSink(Context ctx)
|
||||
{
|
||||
this._context = ctx;
|
||||
}
|
||||
|
||||
// Token: 0x060026D5 RID: 9941 RVA: 0x000800F8 File Offset: 0x0007E2F8
|
||||
public IMessage SyncProcessMessage(IMessage msg)
|
||||
{
|
||||
Context.NotifyGlobalDynamicSinks(true, msg, true, false);
|
||||
this._context.NotifyDynamicSinks(true, msg, true, false);
|
||||
IMessage message;
|
||||
if (msg is IConstructionCallMessage)
|
||||
{
|
||||
message = ActivationServices.RemoteActivate((IConstructionCallMessage)msg);
|
||||
}
|
||||
else
|
||||
{
|
||||
Identity messageTargetIdentity = RemotingServices.GetMessageTargetIdentity(msg);
|
||||
message = messageTargetIdentity.ChannelSink.SyncProcessMessage(msg);
|
||||
}
|
||||
Context.NotifyGlobalDynamicSinks(false, msg, true, false);
|
||||
this._context.NotifyDynamicSinks(false, msg, true, false);
|
||||
return message;
|
||||
}
|
||||
|
||||
// Token: 0x060026D6 RID: 9942 RVA: 0x00080168 File Offset: 0x0007E368
|
||||
public IMessageCtrl AsyncProcessMessage(IMessage msg, IMessageSink replySink)
|
||||
{
|
||||
if (this._context.HasDynamicSinks || Context.HasGlobalDynamicSinks)
|
||||
{
|
||||
Context.NotifyGlobalDynamicSinks(true, msg, true, true);
|
||||
this._context.NotifyDynamicSinks(true, msg, true, true);
|
||||
if (replySink != null)
|
||||
{
|
||||
replySink = new ClientContextReplySink(this._context, replySink);
|
||||
}
|
||||
}
|
||||
Identity messageTargetIdentity = RemotingServices.GetMessageTargetIdentity(msg);
|
||||
IMessageCtrl messageCtrl = messageTargetIdentity.ChannelSink.AsyncProcessMessage(msg, replySink);
|
||||
if (replySink == null && (this._context.HasDynamicSinks || Context.HasGlobalDynamicSinks))
|
||||
{
|
||||
Context.NotifyGlobalDynamicSinks(false, msg, true, true);
|
||||
this._context.NotifyDynamicSinks(false, msg, true, true);
|
||||
}
|
||||
return messageCtrl;
|
||||
}
|
||||
|
||||
// Token: 0x17000749 RID: 1865
|
||||
// (get) Token: 0x060026D7 RID: 9943 RVA: 0x0008020C File Offset: 0x0007E40C
|
||||
public IMessageSink NextSink
|
||||
{
|
||||
get
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F2E RID: 3886
|
||||
private Context _context;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,258 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.Remoting.Activation;
|
||||
using System.Runtime.Remoting.Proxies;
|
||||
using System.Runtime.Serialization;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Implements the <see cref="T:System.Runtime.Remoting.Activation.IConstructionCallMessage" /> interface to create a request message that constitutes a constructor call on a remote object.</summary>
|
||||
// Token: 0x020003E2 RID: 994
|
||||
[CLSCompliant(false)]
|
||||
[ComVisible(true)]
|
||||
[Serializable]
|
||||
public class ConstructionCall : MethodCall, IConstructionCallMessage, IMessage, IMethodCallMessage, IMethodMessage
|
||||
{
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.ConstructionCall" /> class by copying an existing message. </summary>
|
||||
/// <param name="m">A remoting message.</param>
|
||||
// Token: 0x060026DC RID: 9948 RVA: 0x0008026C File Offset: 0x0007E46C
|
||||
public ConstructionCall(IMessage m)
|
||||
: base(m)
|
||||
{
|
||||
this._activationTypeName = this.TypeName;
|
||||
this._isContextOk = true;
|
||||
}
|
||||
|
||||
// Token: 0x060026DD RID: 9949 RVA: 0x00080288 File Offset: 0x0007E488
|
||||
internal ConstructionCall(Type type)
|
||||
{
|
||||
this._activationType = type;
|
||||
this._activationTypeName = type.AssemblyQualifiedName;
|
||||
this._isContextOk = true;
|
||||
}
|
||||
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.ConstructionCall" /> class from an array of remoting headers. </summary>
|
||||
/// <param name="headers">An array of remoting headers that contain key-value pairs. This array is used to initialize <see cref="T:System.Runtime.Remoting.Messaging.ConstructionCall" /> fields for those headers that belong to the namespace "http://schemas.microsoft.com/clr/soap/messageProperties".</param>
|
||||
// Token: 0x060026DE RID: 9950 RVA: 0x000802B8 File Offset: 0x0007E4B8
|
||||
public ConstructionCall(Header[] headers)
|
||||
: base(headers)
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x060026DF RID: 9951 RVA: 0x000802C4 File Offset: 0x0007E4C4
|
||||
internal ConstructionCall(SerializationInfo info, StreamingContext context)
|
||||
: base(info, context)
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x060026E0 RID: 9952 RVA: 0x000802D0 File Offset: 0x0007E4D0
|
||||
internal override void InitDictionary()
|
||||
{
|
||||
ConstructionCallDictionary constructionCallDictionary = new ConstructionCallDictionary(this);
|
||||
this.ExternalProperties = constructionCallDictionary;
|
||||
this.InternalProperties = constructionCallDictionary.GetInternalProperties();
|
||||
}
|
||||
|
||||
// Token: 0x1700074B RID: 1867
|
||||
// (get) Token: 0x060026E1 RID: 9953 RVA: 0x000802F8 File Offset: 0x0007E4F8
|
||||
// (set) Token: 0x060026E2 RID: 9954 RVA: 0x00080300 File Offset: 0x0007E500
|
||||
internal bool IsContextOk
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._isContextOk;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._isContextOk = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the type of the remote object to activate. </summary>
|
||||
/// <returns>The <see cref="T:System.Type" /> of the remote object to activate.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700074C RID: 1868
|
||||
// (get) Token: 0x060026E3 RID: 9955 RVA: 0x0008030C File Offset: 0x0007E50C
|
||||
public Type ActivationType
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._activationType == null)
|
||||
{
|
||||
this._activationType = Type.GetType(this._activationTypeName);
|
||||
}
|
||||
return this._activationType;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the full type name of the remote object to activate. </summary>
|
||||
/// <returns>A <see cref="T:System.String" /> containing the full type name of the remote object to activate.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700074D RID: 1869
|
||||
// (get) Token: 0x060026E4 RID: 9956 RVA: 0x0008033C File Offset: 0x0007E53C
|
||||
public string ActivationTypeName
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._activationTypeName;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets or sets the activator that activates the remote object. </summary>
|
||||
/// <returns>The <see cref="T:System.Runtime.Remoting.Activation.IActivator" /> that activates the remote object.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700074E RID: 1870
|
||||
// (get) Token: 0x060026E5 RID: 9957 RVA: 0x00080344 File Offset: 0x0007E544
|
||||
// (set) Token: 0x060026E6 RID: 9958 RVA: 0x0008034C File Offset: 0x0007E54C
|
||||
public IActivator Activator
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._activator;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._activator = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the call site activation attributes for the remote object. </summary>
|
||||
/// <returns>An array of type <see cref="T:System.Object" /> containing the call site activation attributes for the remote object.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700074F RID: 1871
|
||||
// (get) Token: 0x060026E7 RID: 9959 RVA: 0x00080358 File Offset: 0x0007E558
|
||||
public object[] CallSiteActivationAttributes
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._activationAttributes;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060026E8 RID: 9960 RVA: 0x00080360 File Offset: 0x0007E560
|
||||
internal void SetActivationAttributes(object[] attributes)
|
||||
{
|
||||
this._activationAttributes = attributes;
|
||||
}
|
||||
|
||||
/// <summary>Gets a list of properties that define the context in which the remote object is to be created. </summary>
|
||||
/// <returns>A <see cref="T:System.Collections.IList" /> that contains a list of properties that define the context in which the remote object is to be created.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000750 RID: 1872
|
||||
// (get) Token: 0x060026E9 RID: 9961 RVA: 0x0008036C File Offset: 0x0007E56C
|
||||
public IList ContextProperties
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._contextProperties == null)
|
||||
{
|
||||
this._contextProperties = new ArrayList();
|
||||
}
|
||||
return this._contextProperties;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060026EA RID: 9962 RVA: 0x0008038C File Offset: 0x0007E58C
|
||||
internal override void InitMethodProperty(string key, object value)
|
||||
{
|
||||
switch (key)
|
||||
{
|
||||
case "__Activator":
|
||||
this._activator = (IActivator)value;
|
||||
return;
|
||||
case "__CallSiteActivationAttributes":
|
||||
this._activationAttributes = (object[])value;
|
||||
return;
|
||||
case "__ActivationType":
|
||||
this._activationType = (Type)value;
|
||||
return;
|
||||
case "__ContextProperties":
|
||||
this._contextProperties = (IList)value;
|
||||
return;
|
||||
case "__ActivationTypeName":
|
||||
this._activationTypeName = (string)value;
|
||||
return;
|
||||
}
|
||||
base.InitMethodProperty(key, value);
|
||||
}
|
||||
|
||||
// Token: 0x060026EB RID: 9963 RVA: 0x00080470 File Offset: 0x0007E670
|
||||
public override void GetObjectData(SerializationInfo info, StreamingContext context)
|
||||
{
|
||||
base.GetObjectData(info, context);
|
||||
IList list = this._contextProperties;
|
||||
if (list != null && list.Count == 0)
|
||||
{
|
||||
list = null;
|
||||
}
|
||||
info.AddValue("__Activator", this._activator);
|
||||
info.AddValue("__CallSiteActivationAttributes", this._activationAttributes);
|
||||
info.AddValue("__ActivationType", null);
|
||||
info.AddValue("__ContextProperties", list);
|
||||
info.AddValue("__ActivationTypeName", this._activationTypeName);
|
||||
}
|
||||
|
||||
/// <summary>Gets an <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties. </summary>
|
||||
/// <returns>An <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000751 RID: 1873
|
||||
// (get) Token: 0x060026EC RID: 9964 RVA: 0x000804EC File Offset: 0x0007E6EC
|
||||
public override IDictionary Properties
|
||||
{
|
||||
get
|
||||
{
|
||||
return base.Properties;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000752 RID: 1874
|
||||
// (get) Token: 0x060026ED RID: 9965 RVA: 0x000804F4 File Offset: 0x0007E6F4
|
||||
// (set) Token: 0x060026EE RID: 9966 RVA: 0x000804FC File Offset: 0x0007E6FC
|
||||
internal RemotingProxy SourceProxy
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._sourceProxy;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._sourceProxy = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F31 RID: 3889
|
||||
private IActivator _activator;
|
||||
|
||||
// Token: 0x04000F32 RID: 3890
|
||||
private object[] _activationAttributes;
|
||||
|
||||
// Token: 0x04000F33 RID: 3891
|
||||
private IList _contextProperties;
|
||||
|
||||
// Token: 0x04000F34 RID: 3892
|
||||
private Type _activationType;
|
||||
|
||||
// Token: 0x04000F35 RID: 3893
|
||||
private string _activationTypeName;
|
||||
|
||||
// Token: 0x04000F36 RID: 3894
|
||||
private bool _isContextOk;
|
||||
|
||||
// Token: 0x04000F37 RID: 3895
|
||||
[NonSerialized]
|
||||
private RemotingProxy _sourceProxy;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,76 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.Remoting.Activation;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003E3 RID: 995
|
||||
internal class ConstructionCallDictionary : MethodDictionary
|
||||
{
|
||||
// Token: 0x060026EF RID: 9967 RVA: 0x00080508 File Offset: 0x0007E708
|
||||
public ConstructionCallDictionary(IConstructionCallMessage message)
|
||||
: base(message)
|
||||
{
|
||||
base.MethodKeys = ConstructionCallDictionary.InternalKeys;
|
||||
}
|
||||
|
||||
// Token: 0x060026F1 RID: 9969 RVA: 0x00080590 File Offset: 0x0007E790
|
||||
protected override object GetMethodProperty(string key)
|
||||
{
|
||||
switch (key)
|
||||
{
|
||||
case "__Activator":
|
||||
return ((IConstructionCallMessage)this._message).Activator;
|
||||
case "__CallSiteActivationAttributes":
|
||||
return ((IConstructionCallMessage)this._message).CallSiteActivationAttributes;
|
||||
case "__ActivationType":
|
||||
return ((IConstructionCallMessage)this._message).ActivationType;
|
||||
case "__ContextProperties":
|
||||
return ((IConstructionCallMessage)this._message).ContextProperties;
|
||||
case "__ActivationTypeName":
|
||||
return ((IConstructionCallMessage)this._message).ActivationTypeName;
|
||||
}
|
||||
return base.GetMethodProperty(key);
|
||||
}
|
||||
|
||||
// Token: 0x060026F2 RID: 9970 RVA: 0x00080688 File Offset: 0x0007E888
|
||||
protected override void SetMethodProperty(string key, object value)
|
||||
{
|
||||
if (key != null)
|
||||
{
|
||||
if (ConstructionCallDictionary.<>f__switch$map24 == null)
|
||||
{
|
||||
ConstructionCallDictionary.<>f__switch$map24 = new Dictionary<string, int>(5)
|
||||
{
|
||||
{ "__Activator", 0 },
|
||||
{ "__CallSiteActivationAttributes", 1 },
|
||||
{ "__ActivationType", 1 },
|
||||
{ "__ContextProperties", 1 },
|
||||
{ "__ActivationTypeName", 1 }
|
||||
};
|
||||
}
|
||||
int num;
|
||||
if (ConstructionCallDictionary.<>f__switch$map24.TryGetValue(key, out num))
|
||||
{
|
||||
if (num == 0)
|
||||
{
|
||||
((IConstructionCallMessage)this._message).Activator = (IActivator)value;
|
||||
return;
|
||||
}
|
||||
if (num == 1)
|
||||
{
|
||||
throw new ArgumentException("key was invalid");
|
||||
}
|
||||
}
|
||||
}
|
||||
base.SetMethodProperty(key, value);
|
||||
}
|
||||
|
||||
// Token: 0x04000F39 RID: 3897
|
||||
public static string[] InternalKeys = new string[]
|
||||
{
|
||||
"__Uri", "__MethodName", "__TypeName", "__MethodSignature", "__Args", "__CallContext", "__CallSiteActivationAttributes", "__ActivationType", "__ContextProperties", "__Activator",
|
||||
"__ActivationTypeName"
|
||||
};
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,58 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.Remoting.Activation;
|
||||
using System.Runtime.Serialization;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Implements the <see cref="T:System.Runtime.Remoting.Activation.IConstructionReturnMessage" /> interface to create a message that responds to a call to instantiate a remote object.</summary>
|
||||
// Token: 0x020003E4 RID: 996
|
||||
[ComVisible(true)]
|
||||
[CLSCompliant(false)]
|
||||
[Serializable]
|
||||
public class ConstructionResponse : MethodResponse, IConstructionReturnMessage, IMessage, IMethodMessage, IMethodReturnMessage
|
||||
{
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.ConstructionResponse" /> class from an array of remoting headers and a request message.</summary>
|
||||
/// <param name="h">An array of remoting headers that contain key-value pairs. This array is used to initialize <see cref="T:System.Runtime.Remoting.Messaging.ConstructionResponse" /> fields for those headers that belong to the namespace "http://schemas.microsoft.com/clr/soap/messageProperties".</param>
|
||||
/// <param name="mcm">A request message that constitutes a constructor call on a remote object.</param>
|
||||
// Token: 0x060026F3 RID: 9971 RVA: 0x00080748 File Offset: 0x0007E948
|
||||
public ConstructionResponse(Header[] h, IMethodCallMessage mcm)
|
||||
: base(h, mcm)
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x060026F4 RID: 9972 RVA: 0x00080754 File Offset: 0x0007E954
|
||||
internal ConstructionResponse(object resultObject, LogicalCallContext callCtx, IMethodCallMessage msg)
|
||||
: base(resultObject, null, callCtx, msg)
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x060026F5 RID: 9973 RVA: 0x00080760 File Offset: 0x0007E960
|
||||
internal ConstructionResponse(Exception e, IMethodCallMessage msg)
|
||||
: base(e, msg)
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x060026F6 RID: 9974 RVA: 0x0008076C File Offset: 0x0007E96C
|
||||
internal ConstructionResponse(SerializationInfo info, StreamingContext context)
|
||||
: base(info, context)
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>Gets an <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties. </summary>
|
||||
/// <returns>An <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000753 RID: 1875
|
||||
// (get) Token: 0x060026F7 RID: 9975 RVA: 0x00080778 File Offset: 0x0007E978
|
||||
public override IDictionary Properties
|
||||
{
|
||||
get
|
||||
{
|
||||
return base.Properties;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using System.Threading;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003E5 RID: 997
|
||||
[Serializable]
|
||||
internal class EnvoyTerminatorSink : IMessageSink
|
||||
{
|
||||
// Token: 0x060026FA RID: 9978 RVA: 0x00080794 File Offset: 0x0007E994
|
||||
public IMessage SyncProcessMessage(IMessage msg)
|
||||
{
|
||||
return Thread.CurrentContext.GetClientContextSinkChain().SyncProcessMessage(msg);
|
||||
}
|
||||
|
||||
// Token: 0x060026FB RID: 9979 RVA: 0x000807A8 File Offset: 0x0007E9A8
|
||||
public IMessageCtrl AsyncProcessMessage(IMessage msg, IMessageSink replySink)
|
||||
{
|
||||
return Thread.CurrentContext.GetClientContextSinkChain().AsyncProcessMessage(msg, replySink);
|
||||
}
|
||||
|
||||
// Token: 0x17000754 RID: 1876
|
||||
// (get) Token: 0x060026FC RID: 9980 RVA: 0x000807BC File Offset: 0x0007E9BC
|
||||
public IMessageSink NextSink
|
||||
{
|
||||
get
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F3C RID: 3900
|
||||
public static EnvoyTerminatorSink Instance = new EnvoyTerminatorSink();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,163 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Reflection;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003E6 RID: 998
|
||||
[Serializable]
|
||||
internal class ErrorMessage : IMessage, IMethodCallMessage, IMethodMessage
|
||||
{
|
||||
// Token: 0x17000755 RID: 1877
|
||||
// (get) Token: 0x060026FE RID: 9982 RVA: 0x000807D4 File Offset: 0x0007E9D4
|
||||
public int ArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000756 RID: 1878
|
||||
// (get) Token: 0x060026FF RID: 9983 RVA: 0x000807D8 File Offset: 0x0007E9D8
|
||||
public object[] Args
|
||||
{
|
||||
get
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000757 RID: 1879
|
||||
// (get) Token: 0x06002700 RID: 9984 RVA: 0x000807DC File Offset: 0x0007E9DC
|
||||
public bool HasVarArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000758 RID: 1880
|
||||
// (get) Token: 0x06002701 RID: 9985 RVA: 0x000807E0 File Offset: 0x0007E9E0
|
||||
public MethodBase MethodBase
|
||||
{
|
||||
get
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000759 RID: 1881
|
||||
// (get) Token: 0x06002702 RID: 9986 RVA: 0x000807E4 File Offset: 0x0007E9E4
|
||||
public string MethodName
|
||||
{
|
||||
get
|
||||
{
|
||||
return "unknown";
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x1700075A RID: 1882
|
||||
// (get) Token: 0x06002703 RID: 9987 RVA: 0x000807EC File Offset: 0x0007E9EC
|
||||
public object MethodSignature
|
||||
{
|
||||
get
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x1700075B RID: 1883
|
||||
// (get) Token: 0x06002704 RID: 9988 RVA: 0x000807F0 File Offset: 0x0007E9F0
|
||||
public virtual IDictionary Properties
|
||||
{
|
||||
get
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x1700075C RID: 1884
|
||||
// (get) Token: 0x06002705 RID: 9989 RVA: 0x000807F4 File Offset: 0x0007E9F4
|
||||
public string TypeName
|
||||
{
|
||||
get
|
||||
{
|
||||
return "unknown";
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x1700075D RID: 1885
|
||||
// (get) Token: 0x06002706 RID: 9990 RVA: 0x000807FC File Offset: 0x0007E9FC
|
||||
// (set) Token: 0x06002707 RID: 9991 RVA: 0x00080804 File Offset: 0x0007EA04
|
||||
public string Uri
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._uri;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._uri = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002708 RID: 9992 RVA: 0x00080810 File Offset: 0x0007EA10
|
||||
public object GetArg(int arg_num)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
// Token: 0x06002709 RID: 9993 RVA: 0x00080814 File Offset: 0x0007EA14
|
||||
public string GetArgName(int arg_num)
|
||||
{
|
||||
return "unknown";
|
||||
}
|
||||
|
||||
// Token: 0x1700075E RID: 1886
|
||||
// (get) Token: 0x0600270A RID: 9994 RVA: 0x0008081C File Offset: 0x0007EA1C
|
||||
public int InArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x0600270B RID: 9995 RVA: 0x00080820 File Offset: 0x0007EA20
|
||||
public string GetInArgName(int index)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
// Token: 0x0600270C RID: 9996 RVA: 0x00080824 File Offset: 0x0007EA24
|
||||
public object GetInArg(int argNum)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
// Token: 0x1700075F RID: 1887
|
||||
// (get) Token: 0x0600270D RID: 9997 RVA: 0x00080828 File Offset: 0x0007EA28
|
||||
public object[] InArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000760 RID: 1888
|
||||
// (get) Token: 0x0600270E RID: 9998 RVA: 0x0008082C File Offset: 0x0007EA2C
|
||||
public LogicalCallContext LogicalCallContext
|
||||
{
|
||||
get
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F3D RID: 3901
|
||||
private string _uri = "Exception";
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,61 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Defines the out-of-band data for a call.</summary>
|
||||
// Token: 0x020003E7 RID: 999
|
||||
[ComVisible(true)]
|
||||
[Serializable]
|
||||
public class Header
|
||||
{
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.Header" /> class with the given name and value.</summary>
|
||||
/// <param name="_Name">The name of the <see cref="T:System.Runtime.Remoting.Messaging.Header" />. </param>
|
||||
/// <param name="_Value">The object that contains the value for the <see cref="T:System.Runtime.Remoting.Messaging.Header" />. </param>
|
||||
// Token: 0x0600270F RID: 9999 RVA: 0x00080830 File Offset: 0x0007EA30
|
||||
public Header(string _Name, object _Value)
|
||||
: this(_Name, _Value, true)
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.Header" /> class with the given name, value, and additional configuration information.</summary>
|
||||
/// <param name="_Name">The name of the <see cref="T:System.Runtime.Remoting.Messaging.Header" />. </param>
|
||||
/// <param name="_Value">The object that contains the value for the <see cref="T:System.Runtime.Remoting.Messaging.Header" />. </param>
|
||||
/// <param name="_MustUnderstand">Indicates whether the receiving end must understand the out-of-band data. </param>
|
||||
// Token: 0x06002710 RID: 10000 RVA: 0x0008083C File Offset: 0x0007EA3C
|
||||
public Header(string _Name, object _Value, bool _MustUnderstand)
|
||||
: this(_Name, _Value, _MustUnderstand, null)
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.Header" /> class.</summary>
|
||||
/// <param name="_Name">The name of the <see cref="T:System.Runtime.Remoting.Messaging.Header" />. </param>
|
||||
/// <param name="_Value">The object that contains the value of the <see cref="T:System.Runtime.Remoting.Messaging.Header" />. </param>
|
||||
/// <param name="_MustUnderstand">Indicates whether the receiving end must understand out-of-band data. </param>
|
||||
/// <param name="_HeaderNamespace">The <see cref="T:System.Runtime.Remoting.Messaging.Header" /> XML namespace. </param>
|
||||
// Token: 0x06002711 RID: 10001 RVA: 0x00080848 File Offset: 0x0007EA48
|
||||
public Header(string _Name, object _Value, bool _MustUnderstand, string _HeaderNamespace)
|
||||
{
|
||||
this.Name = _Name;
|
||||
this.Value = _Value;
|
||||
this.MustUnderstand = _MustUnderstand;
|
||||
this.HeaderNamespace = _HeaderNamespace;
|
||||
}
|
||||
|
||||
/// <summary>Indicates the XML namespace that the current <see cref="T:System.Runtime.Remoting.Messaging.Header" /> belongs to.</summary>
|
||||
// Token: 0x04000F3E RID: 3902
|
||||
public string HeaderNamespace;
|
||||
|
||||
/// <summary>Indicates whether the receiving end must understand the out-of-band data.</summary>
|
||||
// Token: 0x04000F3F RID: 3903
|
||||
public bool MustUnderstand;
|
||||
|
||||
/// <summary>Contains the name of the <see cref="T:System.Runtime.Remoting.Messaging.Header" />.</summary>
|
||||
// Token: 0x04000F40 RID: 3904
|
||||
public string Name;
|
||||
|
||||
/// <summary>Contains the value for the <see cref="T:System.Runtime.Remoting.Messaging.Header" />.</summary>
|
||||
// Token: 0x04000F41 RID: 3905
|
||||
public object Value;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Represents the method that will handle processing of headers on the stream during deserialization.</summary>
|
||||
/// <returns>A <see cref="T:System.Object" /> that conveys information about a remote function call.</returns>
|
||||
/// <param name="headers">The headers of the event. </param>
|
||||
// Token: 0x020006DA RID: 1754
|
||||
// (Invoke) Token: 0x060041F0 RID: 16880
|
||||
[ComVisible(true)]
|
||||
public delegate object HeaderHandler(Header[] headers);
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
using System;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003E8 RID: 1000
|
||||
internal interface IInternalMessage
|
||||
{
|
||||
// Token: 0x17000761 RID: 1889
|
||||
// (get) Token: 0x06002712 RID: 10002
|
||||
// (set) Token: 0x06002713 RID: 10003
|
||||
Identity TargetIdentity { get; set; }
|
||||
|
||||
// Token: 0x17000762 RID: 1890
|
||||
// (get) Token: 0x06002714 RID: 10004
|
||||
// (set) Token: 0x06002715 RID: 10005
|
||||
string Uri { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Marks an object that can propagate outside of an <see cref="T:System.AppDomain" /> in a <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" />.</summary>
|
||||
// Token: 0x020003DF RID: 991
|
||||
[ComVisible(true)]
|
||||
public interface ILogicalThreadAffinative
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Contains communication data sent between cooperating message sinks.</summary>
|
||||
// Token: 0x020003E9 RID: 1001
|
||||
[ComVisible(true)]
|
||||
public interface IMessage
|
||||
{
|
||||
/// <summary>Gets an <see cref="T:System.Collections.IDictionary" /> that represents a collection of the message's properties.</summary>
|
||||
/// <returns>A dictionary that represents a collection of the message's properties.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000763 RID: 1891
|
||||
// (get) Token: 0x06002716 RID: 10006
|
||||
IDictionary Properties { get; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Provides a way to control asynchronous messages after they have dispatched using the <see cref="M:System.Runtime.Remoting.Messaging.IMessageSink.AsyncProcessMessage(System.Runtime.Remoting.Messaging.IMessage,System.Runtime.Remoting.Messaging.IMessageSink)" />.</summary>
|
||||
// Token: 0x020003EA RID: 1002
|
||||
[ComVisible(true)]
|
||||
public interface IMessageCtrl
|
||||
{
|
||||
/// <summary>Cancels an asynchronous call.</summary>
|
||||
/// <param name="msToCancel">The number of milliseconds after which to cancel the message. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
// Token: 0x06002717 RID: 10007
|
||||
void Cancel(int msToCancel);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Defines the interface for a message sink.</summary>
|
||||
// Token: 0x020003EB RID: 1003
|
||||
[ComVisible(true)]
|
||||
public interface IMessageSink
|
||||
{
|
||||
/// <summary>Synchronously processes the given message.</summary>
|
||||
/// <returns>A reply message in response to the request.</returns>
|
||||
/// <param name="msg">The message to process. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
// Token: 0x06002718 RID: 10008
|
||||
IMessage SyncProcessMessage(IMessage msg);
|
||||
|
||||
/// <summary>Asynchronously processes the given message.</summary>
|
||||
/// <returns>Returns an <see cref="T:System.Runtime.Remoting.Messaging.IMessageCtrl" /> interface that provides a way to control asynchronous messages after they have been dispatched.</returns>
|
||||
/// <param name="msg">The message to process. </param>
|
||||
/// <param name="replySink">The reply sink for the reply message. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
// Token: 0x06002719 RID: 10009
|
||||
IMessageCtrl AsyncProcessMessage(IMessage msg, IMessageSink replySink);
|
||||
|
||||
/// <summary>Gets the next message sink in the sink chain.</summary>
|
||||
/// <returns>The next message sink in the sink chain.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000764 RID: 1892
|
||||
// (get) Token: 0x0600271A RID: 10010
|
||||
IMessageSink NextSink { get; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Defines the method call message interface.</summary>
|
||||
// Token: 0x020003EC RID: 1004
|
||||
[ComVisible(true)]
|
||||
public interface IMethodCallMessage : IMessage, IMethodMessage
|
||||
{
|
||||
/// <summary>Gets the number of arguments in the call that are not marked as out parameters.</summary>
|
||||
/// <returns>The number of arguments in the call that are not marked as out parameters.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000765 RID: 1893
|
||||
// (get) Token: 0x0600271B RID: 10011
|
||||
int InArgCount { get; }
|
||||
|
||||
/// <summary>Gets an array of arguments that are not marked as out parameters.</summary>
|
||||
/// <returns>An array of arguments that are not marked as out parameters.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000766 RID: 1894
|
||||
// (get) Token: 0x0600271C RID: 10012
|
||||
object[] InArgs { get; }
|
||||
|
||||
/// <summary>Returns the specified argument that is not marked as an out parameter.</summary>
|
||||
/// <returns>The requested argument that is not marked as an out parameter.</returns>
|
||||
/// <param name="argNum">The number of the requested in argument. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
// Token: 0x0600271D RID: 10013
|
||||
object GetInArg(int argNum);
|
||||
|
||||
/// <summary>Returns the name of the specified argument that is not marked as an out parameter.</summary>
|
||||
/// <returns>The name of a specific argument that is not marked as an out parameter.</returns>
|
||||
/// <param name="index">The number of the requested in argument. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
// Token: 0x0600271E RID: 10014
|
||||
string GetInArgName(int index);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,116 @@
|
||||
using System;
|
||||
using System.Reflection;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Defines the method message interface.</summary>
|
||||
// Token: 0x020003ED RID: 1005
|
||||
[ComVisible(true)]
|
||||
public interface IMethodMessage : IMessage
|
||||
{
|
||||
/// <summary>Gets the number of arguments passed to the method.</summary>
|
||||
/// <returns>The number of arguments passed to the method.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000767 RID: 1895
|
||||
// (get) Token: 0x0600271F RID: 10015
|
||||
int ArgCount { get; }
|
||||
|
||||
/// <summary>Gets an array of arguments passed to the method.</summary>
|
||||
/// <returns>An <see cref="T:System.Object" /> array containing the arguments passed to the method.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000768 RID: 1896
|
||||
// (get) Token: 0x06002720 RID: 10016
|
||||
object[] Args { get; }
|
||||
|
||||
/// <summary>Gets a value indicating whether the message has variable arguments.</summary>
|
||||
/// <returns>true if the method can accept a variable number of arguments; otherwise, false.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000769 RID: 1897
|
||||
// (get) Token: 0x06002721 RID: 10017
|
||||
bool HasVarArgs { get; }
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> for the current method call.</summary>
|
||||
/// <returns>Gets the <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> for the current method call.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700076A RID: 1898
|
||||
// (get) Token: 0x06002722 RID: 10018
|
||||
LogicalCallContext LogicalCallContext { get; }
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Reflection.MethodBase" /> of the called method.</summary>
|
||||
/// <returns>The <see cref="T:System.Reflection.MethodBase" /> of the called method.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700076B RID: 1899
|
||||
// (get) Token: 0x06002723 RID: 10019
|
||||
MethodBase MethodBase { get; }
|
||||
|
||||
/// <summary>Gets the name of the invoked method.</summary>
|
||||
/// <returns>The name of the invoked method.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700076C RID: 1900
|
||||
// (get) Token: 0x06002724 RID: 10020
|
||||
string MethodName { get; }
|
||||
|
||||
/// <summary>Gets an object containing the method signature.</summary>
|
||||
/// <returns>An object containing the method signature.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700076D RID: 1901
|
||||
// (get) Token: 0x06002725 RID: 10021
|
||||
object MethodSignature { get; }
|
||||
|
||||
/// <summary>Gets the full <see cref="T:System.Type" /> name of the specific object that the call is destined for.</summary>
|
||||
/// <returns>The full <see cref="T:System.Type" /> name of the specific object that the call is destined for.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700076E RID: 1902
|
||||
// (get) Token: 0x06002726 RID: 10022
|
||||
string TypeName { get; }
|
||||
|
||||
/// <summary>Gets the URI of the specific object that the call is destined for.</summary>
|
||||
/// <returns>The URI of the remote object that contains the invoked method.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700076F RID: 1903
|
||||
// (get) Token: 0x06002727 RID: 10023
|
||||
string Uri { get; }
|
||||
|
||||
/// <summary>Gets a specific argument as an <see cref="T:System.Object" />.</summary>
|
||||
/// <returns>The argument passed to the method.</returns>
|
||||
/// <param name="argNum">The number of the requested argument. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
// Token: 0x06002728 RID: 10024
|
||||
object GetArg(int argNum);
|
||||
|
||||
/// <summary>Gets the name of the argument passed to the method.</summary>
|
||||
/// <returns>The name of the specified argument passed to the method, or null if the current method is not implemented.</returns>
|
||||
/// <param name="index">The number of the requested argument. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
// Token: 0x06002729 RID: 10025
|
||||
string GetArgName(int index);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,65 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Defines the method call return message interface.</summary>
|
||||
// Token: 0x020003EE RID: 1006
|
||||
[ComVisible(true)]
|
||||
public interface IMethodReturnMessage : IMessage, IMethodMessage
|
||||
{
|
||||
/// <summary>Gets the exception thrown during the method call.</summary>
|
||||
/// <returns>The exception object for the method call, or null if the method did not throw an exception.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000770 RID: 1904
|
||||
// (get) Token: 0x0600272A RID: 10026
|
||||
Exception Exception { get; }
|
||||
|
||||
/// <summary>Gets the number of arguments in the method call marked as ref or out parameters.</summary>
|
||||
/// <returns>The number of arguments in the method call marked as ref or out parameters.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000771 RID: 1905
|
||||
// (get) Token: 0x0600272B RID: 10027
|
||||
int OutArgCount { get; }
|
||||
|
||||
/// <summary>Returns the specified argument marked as a ref or an out parameter.</summary>
|
||||
/// <returns>The specified argument marked as a ref or an out parameter.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000772 RID: 1906
|
||||
// (get) Token: 0x0600272C RID: 10028
|
||||
object[] OutArgs { get; }
|
||||
|
||||
/// <summary>Gets the return value of the method call.</summary>
|
||||
/// <returns>The return value of the method call.</returns>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000773 RID: 1907
|
||||
// (get) Token: 0x0600272D RID: 10029
|
||||
object ReturnValue { get; }
|
||||
|
||||
/// <summary>Returns the specified argument marked as a ref or an out parameter.</summary>
|
||||
/// <returns>The specified argument marked as a ref or an out parameter.</returns>
|
||||
/// <param name="argNum">The number of the requested argument. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
// Token: 0x0600272E RID: 10030
|
||||
object GetOutArg(int argNum);
|
||||
|
||||
/// <summary>Returns the name of the specified argument marked as a ref or an out parameter.</summary>
|
||||
/// <returns>The argument name, or null if the current method is not implemented.</returns>
|
||||
/// <param name="index">The number of the requested argument name. </param>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller makes the call through a reference to the interface and does not have infrastructure permission. </exception>
|
||||
// Token: 0x0600272F RID: 10031
|
||||
string GetOutArgName(int index);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.Serialization;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Provides the remote procedure call (RPC) interface for all formatters.</summary>
|
||||
// Token: 0x020003EF RID: 1007
|
||||
[ComVisible(true)]
|
||||
public interface IRemotingFormatter : IFormatter
|
||||
{
|
||||
/// <summary>Begins the deserialization process of a remote procedure call (RPC).</summary>
|
||||
/// <returns>The root of the deserialized object graph.</returns>
|
||||
/// <param name="serializationStream">The <see cref="T:System.IO.Stream" /> from which the data is deserialized. </param>
|
||||
/// <param name="handler">The delegate designed to handle <see cref="T:System.Runtime.Remoting.Messaging.Header" /> objects. Can be null. </param>
|
||||
// Token: 0x06002730 RID: 10032
|
||||
object Deserialize(Stream serializationStream, HeaderHandler handler);
|
||||
|
||||
/// <summary>Starts the serialization process of a remote procedure call (RPC).</summary>
|
||||
/// <param name="serializationStream">The <see cref="T:System.IO.Stream" /> onto which the specified graph is serialized. </param>
|
||||
/// <param name="graph">The root of the object graph to be serialized. </param>
|
||||
/// <param name="headers">The array of <see cref="T:System.Runtime.Remoting.Messaging.Header" /> objects to transmit with the graph specified by the <paramref name="graph" /> parameter. Can be null. </param>
|
||||
// Token: 0x06002731 RID: 10033
|
||||
void Serialize(Stream serializationStream, object graph, Header[] headers);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
using System;
|
||||
using System.Runtime.Serialization;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003F0 RID: 1008
|
||||
internal interface ISerializationRootObject
|
||||
{
|
||||
// Token: 0x06002732 RID: 10034
|
||||
void RootSetObjectData(SerializationInfo info, StreamingContext context);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Wraps remoting data for passing between message sinks, either for requests from client to server or for the subsequent responses.</summary>
|
||||
// Token: 0x020003F1 RID: 1009
|
||||
[ComVisible(true)]
|
||||
public class InternalMessageWrapper
|
||||
{
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.InternalMessageWrapper" /> class. </summary>
|
||||
/// <param name="msg">A message that acts either as an outgoing method call on a remote object, or as the subsequent response.</param>
|
||||
// Token: 0x06002733 RID: 10035 RVA: 0x00080870 File Offset: 0x0007EA70
|
||||
public InternalMessageWrapper(IMessage msg)
|
||||
{
|
||||
this.WrappedMessage = msg;
|
||||
}
|
||||
|
||||
/// <summary>Represents the request or response <see cref="T:System.Runtime.Remoting.Messaging.IMethodMessage" /> interface that is wrapped by the message wrapper. </summary>
|
||||
// Token: 0x04000F42 RID: 3906
|
||||
protected IMessage WrappedMessage;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,157 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.Serialization;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Provides a set of properties that are carried with the execution code path during remote method calls.</summary>
|
||||
// Token: 0x020003F2 RID: 1010
|
||||
[ComVisible(true)]
|
||||
[Serializable]
|
||||
public sealed class LogicalCallContext : ICloneable, ISerializable
|
||||
{
|
||||
// Token: 0x06002734 RID: 10036 RVA: 0x00080880 File Offset: 0x0007EA80
|
||||
internal LogicalCallContext()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x06002735 RID: 10037 RVA: 0x00080894 File Offset: 0x0007EA94
|
||||
internal LogicalCallContext(SerializationInfo info, StreamingContext context)
|
||||
{
|
||||
foreach (SerializationEntry serializationEntry in info)
|
||||
{
|
||||
if (serializationEntry.Name == "__RemotingData")
|
||||
{
|
||||
this._remotingData = (CallContextRemotingData)serializationEntry.Value;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.SetData(serializationEntry.Name, serializationEntry.Value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a value indicating whether the current <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> contains information.</summary>
|
||||
/// <returns>A Boolean value indicating whether the current <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> contains information.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000774 RID: 1908
|
||||
// (get) Token: 0x06002736 RID: 10038 RVA: 0x00080914 File Offset: 0x0007EB14
|
||||
public bool HasInfo
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._data != null && this._data.Count > 0;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Empties a data slot with the specified name.</summary>
|
||||
/// <param name="name">The name of the data slot to empty. </param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002737 RID: 10039 RVA: 0x00080934 File Offset: 0x0007EB34
|
||||
public void FreeNamedDataSlot(string name)
|
||||
{
|
||||
if (this._data != null)
|
||||
{
|
||||
this._data.Remove(name);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Retrieves an object associated with the specified name from the current instance.</summary>
|
||||
/// <returns>The object in the logical call context associated with the specified name.</returns>
|
||||
/// <param name="name">The name of the item in the call context. </param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002738 RID: 10040 RVA: 0x00080950 File Offset: 0x0007EB50
|
||||
public object GetData(string name)
|
||||
{
|
||||
if (this._data != null)
|
||||
{
|
||||
return this._data[name];
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// <summary>Populates a specified <see cref="T:System.Runtime.Serialization.SerializationInfo" /> with the data needed to serialize the current <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" />.</summary>
|
||||
/// <param name="info">The <see cref="T:System.Runtime.Serialization.SerializationInfo" /> to populate with data. </param>
|
||||
/// <param name="context">The contextual information about the source or destination of the serialization. </param>
|
||||
/// <exception cref="T:System.ArgumentNullException">
|
||||
/// <paramref name="info" /> is null. </exception>
|
||||
/// <exception cref="T:System.Security.SecurityException">The immediate caller does not have SerializationFormatter permission. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="SerializationFormatter, Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002739 RID: 10041 RVA: 0x0008096C File Offset: 0x0007EB6C
|
||||
public void GetObjectData(SerializationInfo info, StreamingContext context)
|
||||
{
|
||||
info.AddValue("__RemotingData", this._remotingData);
|
||||
if (this._data != null)
|
||||
{
|
||||
foreach (object obj in this._data)
|
||||
{
|
||||
DictionaryEntry dictionaryEntry = (DictionaryEntry)obj;
|
||||
info.AddValue((string)dictionaryEntry.Key, dictionaryEntry.Value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Stores the specified object in the current instance, and associates it with the specified name.</summary>
|
||||
/// <param name="name">The name with which to associate the new item in the call context. </param>
|
||||
/// <param name="data">The object to store in the call context. </param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x0600273A RID: 10042 RVA: 0x00080A0C File Offset: 0x0007EC0C
|
||||
public void SetData(string name, object data)
|
||||
{
|
||||
if (this._data == null)
|
||||
{
|
||||
this._data = new Hashtable();
|
||||
}
|
||||
this._data[name] = data;
|
||||
}
|
||||
|
||||
/// <summary>Creates a new object that is a copy of the current instance.</summary>
|
||||
/// <returns>A new object that is a copy of this instance.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x0600273B RID: 10043 RVA: 0x00080A34 File Offset: 0x0007EC34
|
||||
public object Clone()
|
||||
{
|
||||
LogicalCallContext logicalCallContext = new LogicalCallContext();
|
||||
logicalCallContext._remotingData = (CallContextRemotingData)this._remotingData.Clone();
|
||||
if (this._data != null)
|
||||
{
|
||||
logicalCallContext._data = new Hashtable();
|
||||
foreach (object obj in this._data)
|
||||
{
|
||||
DictionaryEntry dictionaryEntry = (DictionaryEntry)obj;
|
||||
logicalCallContext._data[dictionaryEntry.Key] = dictionaryEntry.Value;
|
||||
}
|
||||
}
|
||||
return logicalCallContext;
|
||||
}
|
||||
|
||||
// Token: 0x17000775 RID: 1909
|
||||
// (get) Token: 0x0600273C RID: 10044 RVA: 0x00080AE8 File Offset: 0x0007ECE8
|
||||
internal Hashtable Datastore
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._data;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F43 RID: 3907
|
||||
private Hashtable _data;
|
||||
|
||||
// Token: 0x04000F44 RID: 3908
|
||||
private CallContextRemotingData _remotingData = new CallContextRemotingData();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Determines whether the <see cref="T:System.Runtime.Remoting.Messaging.RemotingSurrogateSelector" /> class should ignore a particular <see cref="T:System.Runtime.Remoting.Messaging.IMessage" /> property while creating an <see cref="T:System.Runtime.Remoting.ObjRef" /> for a <see cref="T:System.MarshalByRefObject" /> class.</summary>
|
||||
/// <param name="key"></param>
|
||||
/// <param name="value"></param>
|
||||
// Token: 0x020006DB RID: 1755
|
||||
// (Invoke) Token: 0x060041F4 RID: 16884
|
||||
[ComVisible(true)]
|
||||
public delegate bool MessageSurrogateFilter(string key, object value);
|
||||
}
|
||||
@@ -0,0 +1,664 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Reflection;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.Serialization;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Implements the <see cref="T:System.Runtime.Remoting.Messaging.IMethodCallMessage" /> interface to create a request message that acts as a method call on a remote object.</summary>
|
||||
// Token: 0x020003F4 RID: 1012
|
||||
[CLSCompliant(false)]
|
||||
[ComVisible(true)]
|
||||
[Serializable]
|
||||
public class MethodCall : ISerializable, IInternalMessage, IMessage, IMethodCallMessage, IMethodMessage, ISerializationRootObject
|
||||
{
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.MethodCall" /> class from an array of remoting headers.</summary>
|
||||
/// <param name="h1">An array of remoting headers that contains key/value pairs. This array is used to initialize <see cref="T:System.Runtime.Remoting.Messaging.MethodCall" /> fields for headers that belong to the namespace "http://schemas.microsoft.com/clr/soap/messageProperties".</param>
|
||||
// Token: 0x06002741 RID: 10049 RVA: 0x00080B2C File Offset: 0x0007ED2C
|
||||
public MethodCall(Header[] h1)
|
||||
{
|
||||
this.Init();
|
||||
if (h1 == null || h1.Length == 0)
|
||||
{
|
||||
return;
|
||||
}
|
||||
foreach (Header header in h1)
|
||||
{
|
||||
this.InitMethodProperty(header.Name, header.Value);
|
||||
}
|
||||
this.ResolveMethod();
|
||||
}
|
||||
|
||||
// Token: 0x06002742 RID: 10050 RVA: 0x00080B88 File Offset: 0x0007ED88
|
||||
internal MethodCall(SerializationInfo info, StreamingContext context)
|
||||
{
|
||||
this.Init();
|
||||
foreach (SerializationEntry serializationEntry in info)
|
||||
{
|
||||
this.InitMethodProperty(serializationEntry.Name, serializationEntry.Value);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002743 RID: 10051 RVA: 0x00080BD4 File Offset: 0x0007EDD4
|
||||
internal MethodCall(CADMethodCallMessage msg)
|
||||
{
|
||||
this._uri = string.Copy(msg.Uri);
|
||||
ArrayList arguments = msg.GetArguments();
|
||||
this._args = msg.GetArgs(arguments);
|
||||
this._callContext = msg.GetLogicalCallContext(arguments);
|
||||
if (this._callContext == null)
|
||||
{
|
||||
this._callContext = new LogicalCallContext();
|
||||
}
|
||||
this._methodBase = msg.GetMethod();
|
||||
this.Init();
|
||||
if (msg.PropertiesCount > 0)
|
||||
{
|
||||
CADMessageBase.UnmarshalProperties(this.Properties, msg.PropertiesCount, arguments);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.MethodCall" /> class by copying an existing message.</summary>
|
||||
/// <param name="msg">A remoting message.</param>
|
||||
// Token: 0x06002744 RID: 10052 RVA: 0x00080C60 File Offset: 0x0007EE60
|
||||
public MethodCall(IMessage msg)
|
||||
{
|
||||
if (msg is IMethodMessage)
|
||||
{
|
||||
this.CopyFrom((IMethodMessage)msg);
|
||||
}
|
||||
else
|
||||
{
|
||||
foreach (object obj in msg.Properties)
|
||||
{
|
||||
DictionaryEntry dictionaryEntry = (DictionaryEntry)obj;
|
||||
this.InitMethodProperty((string)dictionaryEntry.Key, dictionaryEntry.Value);
|
||||
}
|
||||
this.Init();
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002745 RID: 10053 RVA: 0x00080D0C File Offset: 0x0007EF0C
|
||||
internal MethodCall(string uri, string typeName, string methodName, object[] args)
|
||||
{
|
||||
this._uri = uri;
|
||||
this._typeName = typeName;
|
||||
this._methodName = methodName;
|
||||
this._args = args;
|
||||
this.Init();
|
||||
this.ResolveMethod();
|
||||
}
|
||||
|
||||
// Token: 0x06002746 RID: 10054 RVA: 0x00080D40 File Offset: 0x0007EF40
|
||||
internal MethodCall()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x17000777 RID: 1911
|
||||
// (get) Token: 0x06002747 RID: 10055 RVA: 0x00080D48 File Offset: 0x0007EF48
|
||||
// (set) Token: 0x06002748 RID: 10056 RVA: 0x00080D50 File Offset: 0x0007EF50
|
||||
string IInternalMessage.Uri
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.Uri;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.Uri = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000778 RID: 1912
|
||||
// (get) Token: 0x06002749 RID: 10057 RVA: 0x00080D5C File Offset: 0x0007EF5C
|
||||
// (set) Token: 0x0600274A RID: 10058 RVA: 0x00080D64 File Offset: 0x0007EF64
|
||||
Identity IInternalMessage.TargetIdentity
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._targetIdentity;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._targetIdentity = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x0600274B RID: 10059 RVA: 0x00080D70 File Offset: 0x0007EF70
|
||||
internal void CopyFrom(IMethodMessage call)
|
||||
{
|
||||
this._uri = call.Uri;
|
||||
this._typeName = call.TypeName;
|
||||
this._methodName = call.MethodName;
|
||||
this._args = call.Args;
|
||||
this._methodSignature = (Type[])call.MethodSignature;
|
||||
this._methodBase = call.MethodBase;
|
||||
this._callContext = call.LogicalCallContext;
|
||||
this.Init();
|
||||
}
|
||||
|
||||
// Token: 0x0600274C RID: 10060 RVA: 0x00080DDC File Offset: 0x0007EFDC
|
||||
internal virtual void InitMethodProperty(string key, object value)
|
||||
{
|
||||
switch (key)
|
||||
{
|
||||
case "__TypeName":
|
||||
this._typeName = (string)value;
|
||||
return;
|
||||
case "__MethodName":
|
||||
this._methodName = (string)value;
|
||||
return;
|
||||
case "__MethodSignature":
|
||||
this._methodSignature = (Type[])value;
|
||||
return;
|
||||
case "__Args":
|
||||
this._args = (object[])value;
|
||||
return;
|
||||
case "__CallContext":
|
||||
this._callContext = (LogicalCallContext)value;
|
||||
return;
|
||||
case "__Uri":
|
||||
this._uri = (string)value;
|
||||
return;
|
||||
case "__GenericArguments":
|
||||
this._genericArguments = (Type[])value;
|
||||
return;
|
||||
}
|
||||
this.Properties[key] = value;
|
||||
}
|
||||
|
||||
/// <summary>The <see cref="M:System.Runtime.Remoting.Messaging.MethodCall.GetObjectData(System.Runtime.Serialization.SerializationInfo,System.Runtime.Serialization.StreamingContext)" /> method is not implemented. </summary>
|
||||
/// <param name="info">The data for serializing or deserializing the remote object.</param>
|
||||
/// <param name="context">The context of a certain serialized stream.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="SerializationFormatter, Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x0600274D RID: 10061 RVA: 0x00080F00 File Offset: 0x0007F100
|
||||
public virtual void GetObjectData(SerializationInfo info, StreamingContext context)
|
||||
{
|
||||
info.AddValue("__TypeName", this._typeName);
|
||||
info.AddValue("__MethodName", this._methodName);
|
||||
info.AddValue("__MethodSignature", this._methodSignature);
|
||||
info.AddValue("__Args", this._args);
|
||||
info.AddValue("__CallContext", this._callContext);
|
||||
info.AddValue("__Uri", this._uri);
|
||||
info.AddValue("__GenericArguments", this._genericArguments);
|
||||
if (this.InternalProperties != null)
|
||||
{
|
||||
foreach (object obj in this.InternalProperties)
|
||||
{
|
||||
DictionaryEntry dictionaryEntry = (DictionaryEntry)obj;
|
||||
info.AddValue((string)dictionaryEntry.Key, dictionaryEntry.Value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the number of arguments passed to a method. </summary>
|
||||
/// <returns>A <see cref="T:System.Int32" /> that represents the number of arguments passed to a method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000779 RID: 1913
|
||||
// (get) Token: 0x0600274E RID: 10062 RVA: 0x00081004 File Offset: 0x0007F204
|
||||
public int ArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._args.Length;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an array of arguments passed to a method. </summary>
|
||||
/// <returns>An array of type <see cref="T:System.Object" /> that represents the arguments passed to a method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700077A RID: 1914
|
||||
// (get) Token: 0x0600274F RID: 10063 RVA: 0x00081010 File Offset: 0x0007F210
|
||||
public object[] Args
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._args;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a value that indicates whether the method can accept a variable number of arguments. </summary>
|
||||
/// <returns>true if the method can accept a variable number of arguments; otherwise, false.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700077B RID: 1915
|
||||
// (get) Token: 0x06002750 RID: 10064 RVA: 0x00081018 File Offset: 0x0007F218
|
||||
public bool HasVarArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
return (this.MethodBase.CallingConvention | CallingConventions.VarArgs) != (CallingConventions)0;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the number of arguments in the method call that are not marked as out parameters.</summary>
|
||||
/// <returns>A <see cref="T:System.Int32" /> that represents the number of arguments in the method call that are not marked as out parameters.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700077C RID: 1916
|
||||
// (get) Token: 0x06002751 RID: 10065 RVA: 0x00081030 File Offset: 0x0007F230
|
||||
public int InArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._inArgInfo == null)
|
||||
{
|
||||
this._inArgInfo = new ArgInfo(this._methodBase, ArgInfoType.In);
|
||||
}
|
||||
return this._inArgInfo.GetInOutArgCount();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an array of arguments in the method call that are not marked as out parameters. </summary>
|
||||
/// <returns>An array of type <see cref="T:System.Object" /> that represents arguments in the method call that are not marked as out parameters.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700077D RID: 1917
|
||||
// (get) Token: 0x06002752 RID: 10066 RVA: 0x00081068 File Offset: 0x0007F268
|
||||
public object[] InArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._inArgInfo == null)
|
||||
{
|
||||
this._inArgInfo = new ArgInfo(this._methodBase, ArgInfoType.In);
|
||||
}
|
||||
return this._inArgInfo.GetInOutArgs(this._args);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> for the current method call. </summary>
|
||||
/// <returns>The <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> for the current method call.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700077E RID: 1918
|
||||
// (get) Token: 0x06002753 RID: 10067 RVA: 0x000810A4 File Offset: 0x0007F2A4
|
||||
public LogicalCallContext LogicalCallContext
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._callContext == null)
|
||||
{
|
||||
this._callContext = new LogicalCallContext();
|
||||
}
|
||||
return this._callContext;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Reflection.MethodBase" /> of the called method. </summary>
|
||||
/// <returns>The <see cref="T:System.Reflection.MethodBase" /> of the called method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700077F RID: 1919
|
||||
// (get) Token: 0x06002754 RID: 10068 RVA: 0x000810C4 File Offset: 0x0007F2C4
|
||||
public MethodBase MethodBase
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._methodBase == null)
|
||||
{
|
||||
this.ResolveMethod();
|
||||
}
|
||||
return this._methodBase;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the name of the invoked method. </summary>
|
||||
/// <returns>A <see cref="T:System.String" /> that contains the name of the invoked method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000780 RID: 1920
|
||||
// (get) Token: 0x06002755 RID: 10069 RVA: 0x000810E0 File Offset: 0x0007F2E0
|
||||
public string MethodName
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._methodName == null)
|
||||
{
|
||||
this._methodName = this._methodBase.Name;
|
||||
}
|
||||
return this._methodName;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an object that contains the method signature. </summary>
|
||||
/// <returns>A <see cref="T:System.Object" /> that contains the method signature.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000781 RID: 1921
|
||||
// (get) Token: 0x06002756 RID: 10070 RVA: 0x00081110 File Offset: 0x0007F310
|
||||
public object MethodSignature
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._methodSignature == null && this._methodBase != null)
|
||||
{
|
||||
ParameterInfo[] parameters = this._methodBase.GetParameters();
|
||||
this._methodSignature = new Type[parameters.Length];
|
||||
for (int i = 0; i < parameters.Length; i++)
|
||||
{
|
||||
this._methodSignature[i] = parameters[i].ParameterType;
|
||||
}
|
||||
}
|
||||
return this._methodSignature;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties. </summary>
|
||||
/// <returns>An <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000782 RID: 1922
|
||||
// (get) Token: 0x06002757 RID: 10071 RVA: 0x00081178 File Offset: 0x0007F378
|
||||
public virtual IDictionary Properties
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.ExternalProperties == null)
|
||||
{
|
||||
this.InitDictionary();
|
||||
}
|
||||
return this.ExternalProperties;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002758 RID: 10072 RVA: 0x00081194 File Offset: 0x0007F394
|
||||
internal virtual void InitDictionary()
|
||||
{
|
||||
MethodCallDictionary methodCallDictionary = new MethodCallDictionary(this);
|
||||
this.ExternalProperties = methodCallDictionary;
|
||||
this.InternalProperties = methodCallDictionary.GetInternalProperties();
|
||||
}
|
||||
|
||||
/// <summary>Gets the full type name of the remote object on which the method call is being made. </summary>
|
||||
/// <returns>A <see cref="T:System.String" /> that contains the full type name of the remote object on which the method call is being made.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000783 RID: 1923
|
||||
// (get) Token: 0x06002759 RID: 10073 RVA: 0x000811BC File Offset: 0x0007F3BC
|
||||
public string TypeName
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._typeName == null)
|
||||
{
|
||||
this._typeName = this._methodBase.DeclaringType.AssemblyQualifiedName;
|
||||
}
|
||||
return this._typeName;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets or sets the Uniform Resource Identifier (URI) of the remote object on which the method call is being made.</summary>
|
||||
/// <returns>The URI of a remote object.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000784 RID: 1924
|
||||
// (get) Token: 0x0600275A RID: 10074 RVA: 0x000811E8 File Offset: 0x0007F3E8
|
||||
// (set) Token: 0x0600275B RID: 10075 RVA: 0x000811F0 File Offset: 0x0007F3F0
|
||||
public string Uri
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._uri;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._uri = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a method argument, as an object, at a specified index. </summary>
|
||||
/// <returns>The method argument as an object.</returns>
|
||||
/// <param name="argNum">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x0600275C RID: 10076 RVA: 0x000811FC File Offset: 0x0007F3FC
|
||||
public object GetArg(int argNum)
|
||||
{
|
||||
return this._args[argNum];
|
||||
}
|
||||
|
||||
/// <summary>Gets the name of a method argument at a specified index. </summary>
|
||||
/// <returns>The name of the method argument.</returns>
|
||||
/// <param name="index">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.ReflectionPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="MemberAccess" />
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x0600275D RID: 10077 RVA: 0x00081208 File Offset: 0x0007F408
|
||||
public string GetArgName(int index)
|
||||
{
|
||||
return this._methodBase.GetParameters()[index].Name;
|
||||
}
|
||||
|
||||
/// <summary>Gets a method argument at a specified index that is not marked as an out parameter. </summary>
|
||||
/// <returns>The method argument that is not marked as an out parameter.</returns>
|
||||
/// <param name="argNum">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x0600275E RID: 10078 RVA: 0x0008121C File Offset: 0x0007F41C
|
||||
public object GetInArg(int argNum)
|
||||
{
|
||||
if (this._inArgInfo == null)
|
||||
{
|
||||
this._inArgInfo = new ArgInfo(this._methodBase, ArgInfoType.In);
|
||||
}
|
||||
return this._args[this._inArgInfo.GetInOutArgIndex(argNum)];
|
||||
}
|
||||
|
||||
/// <summary>Gets the name of a method argument at a specified index that is not marked as an out parameter.</summary>
|
||||
/// <returns>The name of the method argument that is not marked as an out parameter.</returns>
|
||||
/// <param name="index">The index of the requested argument. </param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x0600275F RID: 10079 RVA: 0x0008125C File Offset: 0x0007F45C
|
||||
public string GetInArgName(int index)
|
||||
{
|
||||
if (this._inArgInfo == null)
|
||||
{
|
||||
this._inArgInfo = new ArgInfo(this._methodBase, ArgInfoType.In);
|
||||
}
|
||||
return this._inArgInfo.GetInOutArgName(index);
|
||||
}
|
||||
|
||||
/// <summary>Initializes an internal serialization handler from an array of remoting headers that are applied to a method. </summary>
|
||||
/// <returns>An internal serialization handler.</returns>
|
||||
/// <param name="h">An array of remoting headers that contain key/value pairs. This array is used to initialize <see cref="T:System.Runtime.Remoting.Messaging.MethodCall" /> fields for headers that belong to the namespace "http://schemas.microsoft.com/clr/soap/messageProperties".</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.ReflectionPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="MemberAccess" />
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002760 RID: 10080 RVA: 0x00081288 File Offset: 0x0007F488
|
||||
[MonoTODO]
|
||||
public virtual object HeaderHandler(Header[] h)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
/// <summary>Initializes a <see cref="T:System.Runtime.Remoting.Messaging.MethodCall" />. </summary>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002761 RID: 10081 RVA: 0x00081290 File Offset: 0x0007F490
|
||||
public virtual void Init()
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary>Sets method information from previously initialized remoting message properties. </summary>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.ReflectionPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="MemberAccess" />
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002762 RID: 10082 RVA: 0x00081294 File Offset: 0x0007F494
|
||||
public void ResolveMethod()
|
||||
{
|
||||
if (this._uri != null)
|
||||
{
|
||||
Type serverTypeForUri = RemotingServices.GetServerTypeForUri(this._uri);
|
||||
if (serverTypeForUri == null)
|
||||
{
|
||||
string text = ((this._typeName == null) ? string.Empty : (" (" + this._typeName + ")"));
|
||||
throw new RemotingException("Requested service not found" + text + ". No receiver for uri " + this._uri);
|
||||
}
|
||||
Type type = this.CastTo(this._typeName, serverTypeForUri);
|
||||
if (type == null)
|
||||
{
|
||||
throw new RemotingException(string.Concat(new string[] { "Cannot cast from client type '", this._typeName, "' to server type '", serverTypeForUri.FullName, "'" }));
|
||||
}
|
||||
this._methodBase = RemotingServices.GetMethodBaseFromName(type, this._methodName, this._methodSignature);
|
||||
if (this._methodBase == null)
|
||||
{
|
||||
throw new RemotingException(string.Concat(new object[] { "Method ", this._methodName, " not found in ", type }));
|
||||
}
|
||||
if (type != serverTypeForUri && type.IsInterface && !serverTypeForUri.IsInterface)
|
||||
{
|
||||
this._methodBase = RemotingServices.GetVirtualMethod(serverTypeForUri, this._methodBase);
|
||||
if (this._methodBase == null)
|
||||
{
|
||||
throw new RemotingException(string.Concat(new object[] { "Method ", this._methodName, " not found in ", serverTypeForUri }));
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
this._methodBase = RemotingServices.GetMethodBaseFromMethodMessage(this);
|
||||
if (this._methodBase == null)
|
||||
{
|
||||
throw new RemotingException("Method " + this._methodName + " not found in " + this.TypeName);
|
||||
}
|
||||
}
|
||||
if (this._methodBase.IsGenericMethod && this._methodBase.ContainsGenericParameters)
|
||||
{
|
||||
if (this.GenericArguments == null)
|
||||
{
|
||||
throw new RemotingException("The remoting infrastructure does not support open generic methods.");
|
||||
}
|
||||
this._methodBase = ((MethodInfo)this._methodBase).MakeGenericMethod(this.GenericArguments);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002763 RID: 10083 RVA: 0x0008149C File Offset: 0x0007F69C
|
||||
private Type CastTo(string clientType, Type serverType)
|
||||
{
|
||||
clientType = MethodCall.GetTypeNameFromAssemblyQualifiedName(clientType);
|
||||
if (clientType == serverType.FullName)
|
||||
{
|
||||
return serverType;
|
||||
}
|
||||
for (Type type = serverType.BaseType; type != null; type = type.BaseType)
|
||||
{
|
||||
if (clientType == type.FullName)
|
||||
{
|
||||
return type;
|
||||
}
|
||||
}
|
||||
Type[] interfaces = serverType.GetInterfaces();
|
||||
foreach (Type type2 in interfaces)
|
||||
{
|
||||
if (clientType == type2.FullName)
|
||||
{
|
||||
return type2;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
// Token: 0x06002764 RID: 10084 RVA: 0x0008152C File Offset: 0x0007F72C
|
||||
private static string GetTypeNameFromAssemblyQualifiedName(string aqname)
|
||||
{
|
||||
int num = aqname.IndexOf("]]");
|
||||
int num2 = aqname.IndexOf(',', (num != -1) ? (num + 2) : 0);
|
||||
if (num2 != -1)
|
||||
{
|
||||
aqname = aqname.Substring(0, num2).Trim();
|
||||
}
|
||||
return aqname;
|
||||
}
|
||||
|
||||
/// <summary>Sets method information from serialization settings. </summary>
|
||||
/// <param name="info">The data for serializing or deserializing the remote object.</param>
|
||||
/// <param name="ctx">The context of a given serialized stream.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.ReflectionPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="MemberAccess" />
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002765 RID: 10085 RVA: 0x00081578 File Offset: 0x0007F778
|
||||
[MonoTODO]
|
||||
public void RootSetObjectData(SerializationInfo info, StreamingContext ctx)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
// Token: 0x17000785 RID: 1925
|
||||
// (get) Token: 0x06002766 RID: 10086 RVA: 0x00081580 File Offset: 0x0007F780
|
||||
private Type[] GenericArguments
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._genericArguments != null)
|
||||
{
|
||||
return this._genericArguments;
|
||||
}
|
||||
return this._genericArguments = this.MethodBase.GetGenericArguments();
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F46 RID: 3910
|
||||
private string _uri;
|
||||
|
||||
// Token: 0x04000F47 RID: 3911
|
||||
private string _typeName;
|
||||
|
||||
// Token: 0x04000F48 RID: 3912
|
||||
private string _methodName;
|
||||
|
||||
// Token: 0x04000F49 RID: 3913
|
||||
private object[] _args;
|
||||
|
||||
// Token: 0x04000F4A RID: 3914
|
||||
private Type[] _methodSignature;
|
||||
|
||||
// Token: 0x04000F4B RID: 3915
|
||||
private MethodBase _methodBase;
|
||||
|
||||
// Token: 0x04000F4C RID: 3916
|
||||
private LogicalCallContext _callContext;
|
||||
|
||||
// Token: 0x04000F4D RID: 3917
|
||||
private ArgInfo _inArgInfo;
|
||||
|
||||
// Token: 0x04000F4E RID: 3918
|
||||
private Identity _targetIdentity;
|
||||
|
||||
// Token: 0x04000F4F RID: 3919
|
||||
private Type[] _genericArguments;
|
||||
|
||||
/// <summary>An <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties. </summary>
|
||||
// Token: 0x04000F50 RID: 3920
|
||||
protected IDictionary ExternalProperties;
|
||||
|
||||
/// <summary>An <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties. </summary>
|
||||
// Token: 0x04000F51 RID: 3921
|
||||
protected IDictionary InternalProperties;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
using System;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003F5 RID: 1013
|
||||
internal class MethodCallDictionary : MethodDictionary
|
||||
{
|
||||
// Token: 0x06002767 RID: 10087 RVA: 0x000815B4 File Offset: 0x0007F7B4
|
||||
public MethodCallDictionary(IMethodMessage message)
|
||||
: base(message)
|
||||
{
|
||||
base.MethodKeys = MethodCallDictionary.InternalKeys;
|
||||
}
|
||||
|
||||
// Token: 0x04000F53 RID: 3923
|
||||
public static string[] InternalKeys = new string[] { "__Uri", "__MethodName", "__TypeName", "__MethodSignature", "__Args", "__CallContext" };
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,329 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Reflection;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Implements the <see cref="T:System.Runtime.Remoting.Messaging.IMethodCallMessage" /> interface to create a request message that acts as a method call on a remote object.</summary>
|
||||
// Token: 0x020003F6 RID: 1014
|
||||
[ComVisible(true)]
|
||||
public class MethodCallMessageWrapper : InternalMessageWrapper, IMessage, IMethodCallMessage, IMethodMessage
|
||||
{
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.MethodCallMessageWrapper" /> class by wrapping an <see cref="T:System.Runtime.Remoting.Messaging.IMethodCallMessage" /> interface.</summary>
|
||||
/// <param name="msg">A message that acts as an outgoing method call on a remote object.</param>
|
||||
// Token: 0x06002769 RID: 10089 RVA: 0x00081608 File Offset: 0x0007F808
|
||||
public MethodCallMessageWrapper(IMethodCallMessage msg)
|
||||
: base(msg)
|
||||
{
|
||||
this._args = ((IMethodCallMessage)this.WrappedMessage).Args;
|
||||
this._inArgInfo = new ArgInfo(msg.MethodBase, ArgInfoType.In);
|
||||
}
|
||||
|
||||
/// <summary>Gets the number of arguments passed to the method. </summary>
|
||||
/// <returns>A <see cref="T:System.Int32" /> that represents the number of arguments passed to a method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000786 RID: 1926
|
||||
// (get) Token: 0x0600276A RID: 10090 RVA: 0x00081644 File Offset: 0x0007F844
|
||||
public virtual int ArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodCallMessage)this.WrappedMessage).ArgCount;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an array of arguments passed to the method. </summary>
|
||||
/// <returns>An array of type <see cref="T:System.Object" /> that represents the arguments passed to a method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000787 RID: 1927
|
||||
// (get) Token: 0x0600276B RID: 10091 RVA: 0x00081658 File Offset: 0x0007F858
|
||||
// (set) Token: 0x0600276C RID: 10092 RVA: 0x00081660 File Offset: 0x0007F860
|
||||
public virtual object[] Args
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._args;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._args = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a value indicating whether the method can accept a variable number of arguments. </summary>
|
||||
/// <returns>true if the method can accept a variable number of arguments; otherwise, false.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000788 RID: 1928
|
||||
// (get) Token: 0x0600276D RID: 10093 RVA: 0x0008166C File Offset: 0x0007F86C
|
||||
public virtual bool HasVarArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodCallMessage)this.WrappedMessage).HasVarArgs;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the number of arguments in the method call that are not marked as out parameters. </summary>
|
||||
/// <returns>A <see cref="T:System.Int32" /> that represents the number of arguments in the method call that are not marked as out parameters.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000789 RID: 1929
|
||||
// (get) Token: 0x0600276E RID: 10094 RVA: 0x00081680 File Offset: 0x0007F880
|
||||
public virtual int InArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._inArgInfo.GetInOutArgCount();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an array of arguments in the method call that are not marked as out parameters. </summary>
|
||||
/// <returns>An array of type <see cref="T:System.Object" /> that represents arguments in the method call that are not marked as out parameters.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700078A RID: 1930
|
||||
// (get) Token: 0x0600276F RID: 10095 RVA: 0x00081690 File Offset: 0x0007F890
|
||||
public virtual object[] InArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._inArgInfo.GetInOutArgs(this._args);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> for the current method call. </summary>
|
||||
/// <returns>The <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> for the current method call.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700078B RID: 1931
|
||||
// (get) Token: 0x06002770 RID: 10096 RVA: 0x000816A4 File Offset: 0x0007F8A4
|
||||
public virtual LogicalCallContext LogicalCallContext
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodCallMessage)this.WrappedMessage).LogicalCallContext;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Reflection.MethodBase" /> of the called method. </summary>
|
||||
/// <returns>The <see cref="T:System.Reflection.MethodBase" /> of the called method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700078C RID: 1932
|
||||
// (get) Token: 0x06002771 RID: 10097 RVA: 0x000816B8 File Offset: 0x0007F8B8
|
||||
public virtual MethodBase MethodBase
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodCallMessage)this.WrappedMessage).MethodBase;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the name of the invoked method. </summary>
|
||||
/// <returns>A <see cref="T:System.String" /> that contains the name of the invoked method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700078D RID: 1933
|
||||
// (get) Token: 0x06002772 RID: 10098 RVA: 0x000816CC File Offset: 0x0007F8CC
|
||||
public virtual string MethodName
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodCallMessage)this.WrappedMessage).MethodName;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an object that contains the method signature. </summary>
|
||||
/// <returns>A <see cref="T:System.Object" /> that contains the method signature.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700078E RID: 1934
|
||||
// (get) Token: 0x06002773 RID: 10099 RVA: 0x000816E0 File Offset: 0x0007F8E0
|
||||
public virtual object MethodSignature
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodCallMessage)this.WrappedMessage).MethodSignature;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>An <see cref="T:System.Collections.IDictionary" /> that represents a collection of the remoting message's properties. </summary>
|
||||
/// <returns>An <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x1700078F RID: 1935
|
||||
// (get) Token: 0x06002774 RID: 10100 RVA: 0x000816F4 File Offset: 0x0007F8F4
|
||||
public virtual IDictionary Properties
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._properties == null)
|
||||
{
|
||||
this._properties = new MethodCallMessageWrapper.DictionaryWrapper(this, this.WrappedMessage.Properties);
|
||||
}
|
||||
return this._properties;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the full type name of the remote object on which the method call is being made. </summary>
|
||||
/// <returns>A <see cref="T:System.String" /> that contains the full type name of the remote object on which the method call is being made.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000790 RID: 1936
|
||||
// (get) Token: 0x06002775 RID: 10101 RVA: 0x0008172C File Offset: 0x0007F92C
|
||||
public virtual string TypeName
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodCallMessage)this.WrappedMessage).TypeName;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the Uniform Resource Identifier (URI) of the remote object on which the method call is being made. </summary>
|
||||
/// <returns>The URI of a remote object.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x17000791 RID: 1937
|
||||
// (get) Token: 0x06002776 RID: 10102 RVA: 0x00081740 File Offset: 0x0007F940
|
||||
// (set) Token: 0x06002777 RID: 10103 RVA: 0x00081754 File Offset: 0x0007F954
|
||||
public virtual string Uri
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodCallMessage)this.WrappedMessage).Uri;
|
||||
}
|
||||
set
|
||||
{
|
||||
IInternalMessage internalMessage = this.WrappedMessage as IInternalMessage;
|
||||
if (internalMessage != null)
|
||||
{
|
||||
internalMessage.Uri = value;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.Properties["__Uri"] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a method argument, as an object, at a specified index. </summary>
|
||||
/// <returns>The method argument as an object.</returns>
|
||||
/// <param name="argNum">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002778 RID: 10104 RVA: 0x00081790 File Offset: 0x0007F990
|
||||
public virtual object GetArg(int argNum)
|
||||
{
|
||||
return this._args[argNum];
|
||||
}
|
||||
|
||||
/// <summary>Gets the name of a method argument at a specified index. </summary>
|
||||
/// <returns>The name of the method argument.</returns>
|
||||
/// <param name="index">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002779 RID: 10105 RVA: 0x0008179C File Offset: 0x0007F99C
|
||||
public virtual string GetArgName(int index)
|
||||
{
|
||||
return ((IMethodCallMessage)this.WrappedMessage).GetArgName(index);
|
||||
}
|
||||
|
||||
/// <summary>Gets a method argument at a specified index that is not marked as an out parameter. </summary>
|
||||
/// <returns>The method argument that is not marked as an out parameter.</returns>
|
||||
/// <param name="argNum">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x0600277A RID: 10106 RVA: 0x000817B0 File Offset: 0x0007F9B0
|
||||
public virtual object GetInArg(int argNum)
|
||||
{
|
||||
return this._args[this._inArgInfo.GetInOutArgIndex(argNum)];
|
||||
}
|
||||
|
||||
/// <summary>Gets the name of a method argument at a specified index that is not marked as an out parameter. </summary>
|
||||
/// <returns>The name of the method argument that is not marked as an out parameter.</returns>
|
||||
/// <param name="index">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x0600277B RID: 10107 RVA: 0x000817C8 File Offset: 0x0007F9C8
|
||||
public virtual string GetInArgName(int index)
|
||||
{
|
||||
return this._inArgInfo.GetInOutArgName(index);
|
||||
}
|
||||
|
||||
// Token: 0x04000F54 RID: 3924
|
||||
private object[] _args;
|
||||
|
||||
// Token: 0x04000F55 RID: 3925
|
||||
private ArgInfo _inArgInfo;
|
||||
|
||||
// Token: 0x04000F56 RID: 3926
|
||||
private MethodCallMessageWrapper.DictionaryWrapper _properties;
|
||||
|
||||
// Token: 0x020003F7 RID: 1015
|
||||
private class DictionaryWrapper : MethodCallDictionary
|
||||
{
|
||||
// Token: 0x0600277C RID: 10108 RVA: 0x000817D8 File Offset: 0x0007F9D8
|
||||
public DictionaryWrapper(IMethodMessage message, IDictionary wrappedDictionary)
|
||||
: base(message)
|
||||
{
|
||||
this._wrappedDictionary = wrappedDictionary;
|
||||
base.MethodKeys = MethodCallMessageWrapper.DictionaryWrapper._keys;
|
||||
}
|
||||
|
||||
// Token: 0x0600277E RID: 10110 RVA: 0x0008180C File Offset: 0x0007FA0C
|
||||
protected override IDictionary AllocInternalProperties()
|
||||
{
|
||||
return this._wrappedDictionary;
|
||||
}
|
||||
|
||||
// Token: 0x0600277F RID: 10111 RVA: 0x00081814 File Offset: 0x0007FA14
|
||||
protected override void SetMethodProperty(string key, object value)
|
||||
{
|
||||
if (key == "__Args")
|
||||
{
|
||||
((MethodCallMessageWrapper)this._message)._args = (object[])value;
|
||||
}
|
||||
else
|
||||
{
|
||||
base.SetMethodProperty(key, value);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002780 RID: 10112 RVA: 0x0008184C File Offset: 0x0007FA4C
|
||||
protected override object GetMethodProperty(string key)
|
||||
{
|
||||
if (key == "__Args")
|
||||
{
|
||||
return ((MethodCallMessageWrapper)this._message)._args;
|
||||
}
|
||||
return base.GetMethodProperty(key);
|
||||
}
|
||||
|
||||
// Token: 0x04000F57 RID: 3927
|
||||
private IDictionary _wrappedDictionary;
|
||||
|
||||
// Token: 0x04000F58 RID: 3928
|
||||
private static string[] _keys = new string[] { "__Args" };
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,480 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003F8 RID: 1016
|
||||
[Serializable]
|
||||
internal class MethodDictionary : IEnumerable, ICollection, IDictionary
|
||||
{
|
||||
// Token: 0x06002781 RID: 10113 RVA: 0x00081884 File Offset: 0x0007FA84
|
||||
public MethodDictionary(IMethodMessage message)
|
||||
{
|
||||
this._message = message;
|
||||
}
|
||||
|
||||
// Token: 0x06002782 RID: 10114 RVA: 0x00081894 File Offset: 0x0007FA94
|
||||
public MethodDictionary(string[] keys)
|
||||
{
|
||||
this._methodKeys = keys;
|
||||
}
|
||||
|
||||
// Token: 0x06002783 RID: 10115 RVA: 0x000818A4 File Offset: 0x0007FAA4
|
||||
IEnumerator IEnumerable.GetEnumerator()
|
||||
{
|
||||
return new MethodDictionary.DictionaryEnumerator(this);
|
||||
}
|
||||
|
||||
// Token: 0x17000792 RID: 1938
|
||||
// (get) Token: 0x06002784 RID: 10116 RVA: 0x000818AC File Offset: 0x0007FAAC
|
||||
internal bool HasInternalProperties
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._internalProperties == null)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
if (this._internalProperties is MethodDictionary)
|
||||
{
|
||||
return ((MethodDictionary)this._internalProperties).HasInternalProperties;
|
||||
}
|
||||
return this._internalProperties.Count > 0;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000793 RID: 1939
|
||||
// (get) Token: 0x06002785 RID: 10117 RVA: 0x000818F8 File Offset: 0x0007FAF8
|
||||
internal IDictionary InternalProperties
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._internalProperties != null && this._internalProperties is MethodDictionary)
|
||||
{
|
||||
return ((MethodDictionary)this._internalProperties).InternalProperties;
|
||||
}
|
||||
return this._internalProperties;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000794 RID: 1940
|
||||
// (get) Token: 0x06002786 RID: 10118 RVA: 0x00081938 File Offset: 0x0007FB38
|
||||
// (set) Token: 0x06002787 RID: 10119 RVA: 0x00081940 File Offset: 0x0007FB40
|
||||
public string[] MethodKeys
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._methodKeys;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._methodKeys = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002788 RID: 10120 RVA: 0x0008194C File Offset: 0x0007FB4C
|
||||
protected virtual IDictionary AllocInternalProperties()
|
||||
{
|
||||
this._ownProperties = true;
|
||||
return new Hashtable();
|
||||
}
|
||||
|
||||
// Token: 0x06002789 RID: 10121 RVA: 0x0008195C File Offset: 0x0007FB5C
|
||||
public IDictionary GetInternalProperties()
|
||||
{
|
||||
if (this._internalProperties == null)
|
||||
{
|
||||
this._internalProperties = this.AllocInternalProperties();
|
||||
}
|
||||
return this._internalProperties;
|
||||
}
|
||||
|
||||
// Token: 0x0600278A RID: 10122 RVA: 0x0008197C File Offset: 0x0007FB7C
|
||||
private bool IsOverridenKey(string key)
|
||||
{
|
||||
if (this._ownProperties)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
foreach (string text in this._methodKeys)
|
||||
{
|
||||
if (key == text)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// Token: 0x17000795 RID: 1941
|
||||
// (get) Token: 0x0600278B RID: 10123 RVA: 0x000819C4 File Offset: 0x0007FBC4
|
||||
public bool IsFixedSize
|
||||
{
|
||||
get
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000796 RID: 1942
|
||||
// (get) Token: 0x0600278C RID: 10124 RVA: 0x000819C8 File Offset: 0x0007FBC8
|
||||
public bool IsReadOnly
|
||||
{
|
||||
get
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000797 RID: 1943
|
||||
public object this[object key]
|
||||
{
|
||||
get
|
||||
{
|
||||
string text = (string)key;
|
||||
for (int i = 0; i < this._methodKeys.Length; i++)
|
||||
{
|
||||
if (this._methodKeys[i] == text)
|
||||
{
|
||||
return this.GetMethodProperty(text);
|
||||
}
|
||||
}
|
||||
if (this._internalProperties != null)
|
||||
{
|
||||
return this._internalProperties[key];
|
||||
}
|
||||
return null;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.Add(key, value);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x0600278F RID: 10127 RVA: 0x00081A3C File Offset: 0x0007FC3C
|
||||
protected virtual object GetMethodProperty(string key)
|
||||
{
|
||||
switch (key)
|
||||
{
|
||||
case "__Uri":
|
||||
return this._message.Uri;
|
||||
case "__MethodName":
|
||||
return this._message.MethodName;
|
||||
case "__TypeName":
|
||||
return this._message.TypeName;
|
||||
case "__MethodSignature":
|
||||
return this._message.MethodSignature;
|
||||
case "__CallContext":
|
||||
return this._message.LogicalCallContext;
|
||||
case "__Args":
|
||||
return this._message.Args;
|
||||
case "__OutArgs":
|
||||
return ((IMethodReturnMessage)this._message).OutArgs;
|
||||
case "__Return":
|
||||
return ((IMethodReturnMessage)this._message).ReturnValue;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
// Token: 0x06002790 RID: 10128 RVA: 0x00081B70 File Offset: 0x0007FD70
|
||||
protected virtual void SetMethodProperty(string key, object value)
|
||||
{
|
||||
switch (key)
|
||||
{
|
||||
case "__CallContext":
|
||||
case "__OutArgs":
|
||||
case "__Return":
|
||||
return;
|
||||
case "__MethodName":
|
||||
case "__TypeName":
|
||||
case "__MethodSignature":
|
||||
case "__Args":
|
||||
throw new ArgumentException("key was invalid");
|
||||
case "__Uri":
|
||||
((IInternalMessage)this._message).Uri = (string)value;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000798 RID: 1944
|
||||
// (get) Token: 0x06002791 RID: 10129 RVA: 0x00081C48 File Offset: 0x0007FE48
|
||||
public ICollection Keys
|
||||
{
|
||||
get
|
||||
{
|
||||
ArrayList arrayList = new ArrayList();
|
||||
for (int i = 0; i < this._methodKeys.Length; i++)
|
||||
{
|
||||
arrayList.Add(this._methodKeys[i]);
|
||||
}
|
||||
if (this._internalProperties != null)
|
||||
{
|
||||
foreach (object obj in this._internalProperties.Keys)
|
||||
{
|
||||
string text = (string)obj;
|
||||
if (!this.IsOverridenKey(text))
|
||||
{
|
||||
arrayList.Add(text);
|
||||
}
|
||||
}
|
||||
}
|
||||
return arrayList;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17000799 RID: 1945
|
||||
// (get) Token: 0x06002792 RID: 10130 RVA: 0x00081D08 File Offset: 0x0007FF08
|
||||
public ICollection Values
|
||||
{
|
||||
get
|
||||
{
|
||||
ArrayList arrayList = new ArrayList();
|
||||
for (int i = 0; i < this._methodKeys.Length; i++)
|
||||
{
|
||||
arrayList.Add(this.GetMethodProperty(this._methodKeys[i]));
|
||||
}
|
||||
if (this._internalProperties != null)
|
||||
{
|
||||
foreach (object obj in this._internalProperties)
|
||||
{
|
||||
DictionaryEntry dictionaryEntry = (DictionaryEntry)obj;
|
||||
if (!this.IsOverridenKey((string)dictionaryEntry.Key))
|
||||
{
|
||||
arrayList.Add(dictionaryEntry.Value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return arrayList;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002793 RID: 10131 RVA: 0x00081DD8 File Offset: 0x0007FFD8
|
||||
public void Add(object key, object value)
|
||||
{
|
||||
string text = (string)key;
|
||||
for (int i = 0; i < this._methodKeys.Length; i++)
|
||||
{
|
||||
if (this._methodKeys[i] == text)
|
||||
{
|
||||
this.SetMethodProperty(text, value);
|
||||
return;
|
||||
}
|
||||
}
|
||||
if (this._internalProperties == null)
|
||||
{
|
||||
this._internalProperties = this.AllocInternalProperties();
|
||||
}
|
||||
this._internalProperties[key] = value;
|
||||
}
|
||||
|
||||
// Token: 0x06002794 RID: 10132 RVA: 0x00081E48 File Offset: 0x00080048
|
||||
public void Clear()
|
||||
{
|
||||
if (this._internalProperties != null)
|
||||
{
|
||||
this._internalProperties.Clear();
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002795 RID: 10133 RVA: 0x00081E60 File Offset: 0x00080060
|
||||
public bool Contains(object key)
|
||||
{
|
||||
string text = (string)key;
|
||||
for (int i = 0; i < this._methodKeys.Length; i++)
|
||||
{
|
||||
if (this._methodKeys[i] == text)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return this._internalProperties != null && this._internalProperties.Contains(key);
|
||||
}
|
||||
|
||||
// Token: 0x06002796 RID: 10134 RVA: 0x00081EBC File Offset: 0x000800BC
|
||||
public void Remove(object key)
|
||||
{
|
||||
string text = (string)key;
|
||||
for (int i = 0; i < this._methodKeys.Length; i++)
|
||||
{
|
||||
if (this._methodKeys[i] == text)
|
||||
{
|
||||
throw new ArgumentException("key was invalid");
|
||||
}
|
||||
}
|
||||
if (this._internalProperties != null)
|
||||
{
|
||||
this._internalProperties.Remove(key);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x1700079A RID: 1946
|
||||
// (get) Token: 0x06002797 RID: 10135 RVA: 0x00081F20 File Offset: 0x00080120
|
||||
public int Count
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._internalProperties != null)
|
||||
{
|
||||
return this._internalProperties.Count + this._methodKeys.Length;
|
||||
}
|
||||
return this._methodKeys.Length;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x1700079B RID: 1947
|
||||
// (get) Token: 0x06002798 RID: 10136 RVA: 0x00081F58 File Offset: 0x00080158
|
||||
public bool IsSynchronized
|
||||
{
|
||||
get
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x1700079C RID: 1948
|
||||
// (get) Token: 0x06002799 RID: 10137 RVA: 0x00081F5C File Offset: 0x0008015C
|
||||
public object SyncRoot
|
||||
{
|
||||
get
|
||||
{
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x0600279A RID: 10138 RVA: 0x00081F60 File Offset: 0x00080160
|
||||
public void CopyTo(Array array, int index)
|
||||
{
|
||||
this.Values.CopyTo(array, index);
|
||||
}
|
||||
|
||||
// Token: 0x0600279B RID: 10139 RVA: 0x00081F70 File Offset: 0x00080170
|
||||
public IDictionaryEnumerator GetEnumerator()
|
||||
{
|
||||
return new MethodDictionary.DictionaryEnumerator(this);
|
||||
}
|
||||
|
||||
// Token: 0x04000F59 RID: 3929
|
||||
private IDictionary _internalProperties;
|
||||
|
||||
// Token: 0x04000F5A RID: 3930
|
||||
protected IMethodMessage _message;
|
||||
|
||||
// Token: 0x04000F5B RID: 3931
|
||||
private string[] _methodKeys;
|
||||
|
||||
// Token: 0x04000F5C RID: 3932
|
||||
private bool _ownProperties;
|
||||
|
||||
// Token: 0x020003F9 RID: 1017
|
||||
private class DictionaryEnumerator : IEnumerator, IDictionaryEnumerator
|
||||
{
|
||||
// Token: 0x0600279C RID: 10140 RVA: 0x00081F78 File Offset: 0x00080178
|
||||
public DictionaryEnumerator(MethodDictionary methodDictionary)
|
||||
{
|
||||
this._methodDictionary = methodDictionary;
|
||||
IDictionaryEnumerator dictionaryEnumerator;
|
||||
if (this._methodDictionary._internalProperties != null)
|
||||
{
|
||||
IDictionaryEnumerator enumerator = this._methodDictionary._internalProperties.GetEnumerator();
|
||||
dictionaryEnumerator = enumerator;
|
||||
}
|
||||
else
|
||||
{
|
||||
dictionaryEnumerator = null;
|
||||
}
|
||||
this._hashtableEnum = dictionaryEnumerator;
|
||||
this._posMethod = -1;
|
||||
}
|
||||
|
||||
// Token: 0x1700079D RID: 1949
|
||||
// (get) Token: 0x0600279D RID: 10141 RVA: 0x00081FC8 File Offset: 0x000801C8
|
||||
public object Current
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.Entry.Value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x0600279E RID: 10142 RVA: 0x00081FE4 File Offset: 0x000801E4
|
||||
public bool MoveNext()
|
||||
{
|
||||
if (this._posMethod != -2)
|
||||
{
|
||||
this._posMethod++;
|
||||
if (this._posMethod < this._methodDictionary._methodKeys.Length)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
this._posMethod = -2;
|
||||
}
|
||||
if (this._hashtableEnum == null)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
while (this._hashtableEnum.MoveNext())
|
||||
{
|
||||
if (!this._methodDictionary.IsOverridenKey((string)this._hashtableEnum.Key))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// Token: 0x0600279F RID: 10143 RVA: 0x00082074 File Offset: 0x00080274
|
||||
public void Reset()
|
||||
{
|
||||
this._posMethod = -1;
|
||||
this._hashtableEnum.Reset();
|
||||
}
|
||||
|
||||
// Token: 0x1700079E RID: 1950
|
||||
// (get) Token: 0x060027A0 RID: 10144 RVA: 0x00082088 File Offset: 0x00080288
|
||||
public DictionaryEntry Entry
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._posMethod >= 0)
|
||||
{
|
||||
return new DictionaryEntry(this._methodDictionary._methodKeys[this._posMethod], this._methodDictionary.GetMethodProperty(this._methodDictionary._methodKeys[this._posMethod]));
|
||||
}
|
||||
if (this._posMethod == -1 || this._hashtableEnum == null)
|
||||
{
|
||||
throw new InvalidOperationException("The enumerator is positioned before the first element of the collection or after the last element");
|
||||
}
|
||||
return this._hashtableEnum.Entry;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x1700079F RID: 1951
|
||||
// (get) Token: 0x060027A1 RID: 10145 RVA: 0x00082104 File Offset: 0x00080304
|
||||
public object Key
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.Entry.Key;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007A0 RID: 1952
|
||||
// (get) Token: 0x060027A2 RID: 10146 RVA: 0x00082120 File Offset: 0x00080320
|
||||
public object Value
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.Entry.Value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F5F RID: 3935
|
||||
private MethodDictionary _methodDictionary;
|
||||
|
||||
// Token: 0x04000F60 RID: 3936
|
||||
private IDictionaryEnumerator _hashtableEnum;
|
||||
|
||||
// Token: 0x04000F61 RID: 3937
|
||||
private int _posMethod;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,608 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Reflection;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.Serialization;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Implements the <see cref="T:System.Runtime.Remoting.Messaging.IMethodReturnMessage" /> interface to create a message that acts as a method response on a remote object.</summary>
|
||||
// Token: 0x020003FA RID: 1018
|
||||
[ComVisible(true)]
|
||||
[CLSCompliant(false)]
|
||||
[Serializable]
|
||||
public class MethodResponse : ISerializable, IInternalMessage, IMessage, IMethodMessage, IMethodReturnMessage, ISerializationRootObject
|
||||
{
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.MethodResponse" /> class from an array of remoting headers and a request message. </summary>
|
||||
/// <param name="h1">An array of remoting headers that contains key/value pairs. This array is used to initialize <see cref="T:System.Runtime.Remoting.Messaging.MethodResponse" /> fields for headers that belong to the namespace "http://schemas.microsoft.com/clr/soap/messageProperties".</param>
|
||||
/// <param name="mcm">A request message that acts as a method call on a remote object.</param>
|
||||
// Token: 0x060027A3 RID: 10147 RVA: 0x0008213C File Offset: 0x0008033C
|
||||
public MethodResponse(Header[] h1, IMethodCallMessage mcm)
|
||||
{
|
||||
if (mcm != null)
|
||||
{
|
||||
this._methodName = mcm.MethodName;
|
||||
this._uri = mcm.Uri;
|
||||
this._typeName = mcm.TypeName;
|
||||
this._methodBase = mcm.MethodBase;
|
||||
this._methodSignature = (Type[])mcm.MethodSignature;
|
||||
this._args = mcm.Args;
|
||||
}
|
||||
if (h1 != null)
|
||||
{
|
||||
foreach (Header header in h1)
|
||||
{
|
||||
this.InitMethodProperty(header.Name, header.Value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060027A4 RID: 10148 RVA: 0x000821D4 File Offset: 0x000803D4
|
||||
internal MethodResponse(Exception e, IMethodCallMessage msg)
|
||||
{
|
||||
this._callMsg = msg;
|
||||
if (msg != null)
|
||||
{
|
||||
this._uri = msg.Uri;
|
||||
}
|
||||
else
|
||||
{
|
||||
this._uri = string.Empty;
|
||||
}
|
||||
this._exception = e;
|
||||
this._returnValue = null;
|
||||
this._outArgs = new object[0];
|
||||
}
|
||||
|
||||
// Token: 0x060027A5 RID: 10149 RVA: 0x0008222C File Offset: 0x0008042C
|
||||
internal MethodResponse(object returnValue, object[] outArgs, LogicalCallContext callCtx, IMethodCallMessage msg)
|
||||
{
|
||||
this._callMsg = msg;
|
||||
this._uri = msg.Uri;
|
||||
this._exception = null;
|
||||
this._returnValue = returnValue;
|
||||
this._args = outArgs;
|
||||
}
|
||||
|
||||
// Token: 0x060027A6 RID: 10150 RVA: 0x0008226C File Offset: 0x0008046C
|
||||
internal MethodResponse(IMethodCallMessage msg, CADMethodReturnMessage retmsg)
|
||||
{
|
||||
this._callMsg = msg;
|
||||
this._methodBase = msg.MethodBase;
|
||||
this._uri = msg.Uri;
|
||||
this._methodName = msg.MethodName;
|
||||
ArrayList arguments = retmsg.GetArguments();
|
||||
this._exception = retmsg.GetException(arguments);
|
||||
this._returnValue = retmsg.GetReturnValue(arguments);
|
||||
this._args = retmsg.GetArgs(arguments);
|
||||
this._callContext = retmsg.GetLogicalCallContext(arguments);
|
||||
if (this._callContext == null)
|
||||
{
|
||||
this._callContext = new LogicalCallContext();
|
||||
}
|
||||
if (retmsg.PropertiesCount > 0)
|
||||
{
|
||||
CADMessageBase.UnmarshalProperties(this.Properties, retmsg.PropertiesCount, arguments);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060027A7 RID: 10151 RVA: 0x0008231C File Offset: 0x0008051C
|
||||
internal MethodResponse(SerializationInfo info, StreamingContext context)
|
||||
{
|
||||
foreach (SerializationEntry serializationEntry in info)
|
||||
{
|
||||
this.InitMethodProperty(serializationEntry.Name, serializationEntry.Value);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007A1 RID: 1953
|
||||
// (get) Token: 0x060027A8 RID: 10152 RVA: 0x00082364 File Offset: 0x00080564
|
||||
// (set) Token: 0x060027A9 RID: 10153 RVA: 0x0008236C File Offset: 0x0008056C
|
||||
string IInternalMessage.Uri
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.Uri;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.Uri = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007A2 RID: 1954
|
||||
// (get) Token: 0x060027AA RID: 10154 RVA: 0x00082378 File Offset: 0x00080578
|
||||
// (set) Token: 0x060027AB RID: 10155 RVA: 0x00082380 File Offset: 0x00080580
|
||||
Identity IInternalMessage.TargetIdentity
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._targetIdentity;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._targetIdentity = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060027AC RID: 10156 RVA: 0x0008238C File Offset: 0x0008058C
|
||||
internal void InitMethodProperty(string key, object value)
|
||||
{
|
||||
switch (key)
|
||||
{
|
||||
case "__TypeName":
|
||||
this._typeName = (string)value;
|
||||
return;
|
||||
case "__MethodName":
|
||||
this._methodName = (string)value;
|
||||
return;
|
||||
case "__MethodSignature":
|
||||
this._methodSignature = (Type[])value;
|
||||
return;
|
||||
case "__Uri":
|
||||
this._uri = (string)value;
|
||||
return;
|
||||
case "__Return":
|
||||
this._returnValue = value;
|
||||
return;
|
||||
case "__OutArgs":
|
||||
this._args = (object[])value;
|
||||
return;
|
||||
case "__fault":
|
||||
this._exception = (Exception)value;
|
||||
return;
|
||||
case "__CallContext":
|
||||
this._callContext = (LogicalCallContext)value;
|
||||
return;
|
||||
}
|
||||
this.Properties[key] = value;
|
||||
}
|
||||
|
||||
/// <summary>Gets the number of arguments passed to the method. </summary>
|
||||
/// <returns>A <see cref="T:System.Int32" /> that represents the number of arguments passed to a method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007A3 RID: 1955
|
||||
// (get) Token: 0x060027AD RID: 10157 RVA: 0x000824EC File Offset: 0x000806EC
|
||||
public int ArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._args == null)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
return this._args.Length;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an array of arguments passed to the method. </summary>
|
||||
/// <returns>An array of type <see cref="T:System.Object" /> that represents the arguments passed to a method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007A4 RID: 1956
|
||||
// (get) Token: 0x060027AE RID: 10158 RVA: 0x00082504 File Offset: 0x00080704
|
||||
public object[] Args
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._args;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the exception thrown during the method call, or null if the method did not throw an exception. </summary>
|
||||
/// <returns>The <see cref="T:System.Exception" /> thrown during the method call, or null if the method did not throw an exception.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007A5 RID: 1957
|
||||
// (get) Token: 0x060027AF RID: 10159 RVA: 0x0008250C File Offset: 0x0008070C
|
||||
public Exception Exception
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._exception;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a value that indicates whether the method can accept a variable number of arguments. </summary>
|
||||
/// <returns>true if the method can accept a variable number of arguments; otherwise, false.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007A6 RID: 1958
|
||||
// (get) Token: 0x060027B0 RID: 10160 RVA: 0x00082514 File Offset: 0x00080714
|
||||
public bool HasVarArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
return (this.MethodBase.CallingConvention | CallingConventions.VarArgs) != (CallingConventions)0;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> for the current method call. </summary>
|
||||
/// <returns>The <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> for the current method call.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007A7 RID: 1959
|
||||
// (get) Token: 0x060027B1 RID: 10161 RVA: 0x0008252C File Offset: 0x0008072C
|
||||
public LogicalCallContext LogicalCallContext
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._callContext == null)
|
||||
{
|
||||
this._callContext = new LogicalCallContext();
|
||||
}
|
||||
return this._callContext;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Reflection.MethodBase" /> of the called method. </summary>
|
||||
/// <returns>The <see cref="T:System.Reflection.MethodBase" /> of the called method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007A8 RID: 1960
|
||||
// (get) Token: 0x060027B2 RID: 10162 RVA: 0x0008254C File Offset: 0x0008074C
|
||||
public MethodBase MethodBase
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._methodBase == null)
|
||||
{
|
||||
if (this._callMsg != null)
|
||||
{
|
||||
this._methodBase = this._callMsg.MethodBase;
|
||||
}
|
||||
else if (this.MethodName != null && this.TypeName != null)
|
||||
{
|
||||
this._methodBase = RemotingServices.GetMethodBaseFromMethodMessage(this);
|
||||
}
|
||||
}
|
||||
return this._methodBase;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the name of the invoked method. </summary>
|
||||
/// <returns>A <see cref="T:System.String" /> that contains the name of the invoked method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007A9 RID: 1961
|
||||
// (get) Token: 0x060027B3 RID: 10163 RVA: 0x000825B0 File Offset: 0x000807B0
|
||||
public string MethodName
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._methodName == null && this._callMsg != null)
|
||||
{
|
||||
this._methodName = this._callMsg.MethodName;
|
||||
}
|
||||
return this._methodName;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an object that contains the method signature. </summary>
|
||||
/// <returns>A <see cref="T:System.Object" /> that contains the method signature.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007AA RID: 1962
|
||||
// (get) Token: 0x060027B4 RID: 10164 RVA: 0x000825E0 File Offset: 0x000807E0
|
||||
public object MethodSignature
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._methodSignature == null && this._callMsg != null)
|
||||
{
|
||||
this._methodSignature = (Type[])this._callMsg.MethodSignature;
|
||||
}
|
||||
return this._methodSignature;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the number of arguments in the method call marked as ref or out parameters.</summary>
|
||||
/// <returns>A <see cref="T:System.Int32" /> that represents the number of arguments in the method call marked as ref or out parameters.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007AB RID: 1963
|
||||
// (get) Token: 0x060027B5 RID: 10165 RVA: 0x00082620 File Offset: 0x00080820
|
||||
public int OutArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._args == null || this._args.Length == 0)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
if (this._inArgInfo == null)
|
||||
{
|
||||
this._inArgInfo = new ArgInfo(this.MethodBase, ArgInfoType.Out);
|
||||
}
|
||||
return this._inArgInfo.GetInOutArgCount();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an array of arguments in the method call that are marked as ref or out parameters.</summary>
|
||||
/// <returns>An array of type <see cref="T:System.Object" /> that represents the arguments in the method call that are marked as ref or out parameters.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007AC RID: 1964
|
||||
// (get) Token: 0x060027B6 RID: 10166 RVA: 0x00082670 File Offset: 0x00080870
|
||||
public object[] OutArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._outArgs == null && this._args != null)
|
||||
{
|
||||
if (this._inArgInfo == null)
|
||||
{
|
||||
this._inArgInfo = new ArgInfo(this.MethodBase, ArgInfoType.Out);
|
||||
}
|
||||
this._outArgs = this._inArgInfo.GetInOutArgs(this._args);
|
||||
}
|
||||
return this._outArgs;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties. </summary>
|
||||
/// <returns>An <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007AD RID: 1965
|
||||
// (get) Token: 0x060027B7 RID: 10167 RVA: 0x000826D0 File Offset: 0x000808D0
|
||||
public virtual IDictionary Properties
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.ExternalProperties == null)
|
||||
{
|
||||
MethodReturnDictionary methodReturnDictionary = new MethodReturnDictionary(this);
|
||||
this.ExternalProperties = methodReturnDictionary;
|
||||
this.InternalProperties = methodReturnDictionary.GetInternalProperties();
|
||||
}
|
||||
return this.ExternalProperties;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the return value of the method call. </summary>
|
||||
/// <returns>A <see cref="T:System.Object" /> that represents the return value of the method call.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007AE RID: 1966
|
||||
// (get) Token: 0x060027B8 RID: 10168 RVA: 0x00082708 File Offset: 0x00080908
|
||||
public object ReturnValue
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._returnValue;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the full type name of the remote object on which the method call is being made. </summary>
|
||||
/// <returns>A <see cref="T:System.String" /> that contains the full type name of the remote object on which the method call is being made.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007AF RID: 1967
|
||||
// (get) Token: 0x060027B9 RID: 10169 RVA: 0x00082710 File Offset: 0x00080910
|
||||
public string TypeName
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._typeName == null && this._callMsg != null)
|
||||
{
|
||||
this._typeName = this._callMsg.TypeName;
|
||||
}
|
||||
return this._typeName;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the Uniform Resource Identifier (URI) of the remote object on which the method call is being made. </summary>
|
||||
/// <returns>The URI of a remote object.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007B0 RID: 1968
|
||||
// (get) Token: 0x060027BA RID: 10170 RVA: 0x00082740 File Offset: 0x00080940
|
||||
// (set) Token: 0x060027BB RID: 10171 RVA: 0x00082770 File Offset: 0x00080970
|
||||
public string Uri
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._uri == null && this._callMsg != null)
|
||||
{
|
||||
this._uri = this._callMsg.Uri;
|
||||
}
|
||||
return this._uri;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._uri = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a method argument, as an object, at a specified index. </summary>
|
||||
/// <returns>The method argument as an object.</returns>
|
||||
/// <param name="argNum">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060027BC RID: 10172 RVA: 0x0008277C File Offset: 0x0008097C
|
||||
public object GetArg(int argNum)
|
||||
{
|
||||
if (this._args == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return this._args[argNum];
|
||||
}
|
||||
|
||||
/// <summary>Gets the name of a method argument at a specified index. </summary>
|
||||
/// <returns>The name of the method argument.</returns>
|
||||
/// <param name="index">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060027BD RID: 10173 RVA: 0x00082794 File Offset: 0x00080994
|
||||
public string GetArgName(int index)
|
||||
{
|
||||
return this.MethodBase.GetParameters()[index].Name;
|
||||
}
|
||||
|
||||
/// <summary>The <see cref="M:System.Runtime.Remoting.Messaging.MethodResponse.GetObjectData(System.Runtime.Serialization.SerializationInfo,System.Runtime.Serialization.StreamingContext)" /> method is not implemented. </summary>
|
||||
/// <param name="info">Data for serializing or deserializing the remote object.</param>
|
||||
/// <param name="context">Context of a certain serialized stream.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="SerializationFormatter, Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060027BE RID: 10174 RVA: 0x000827A8 File Offset: 0x000809A8
|
||||
public virtual void GetObjectData(SerializationInfo info, StreamingContext context)
|
||||
{
|
||||
if (this._exception == null)
|
||||
{
|
||||
info.AddValue("__TypeName", this._typeName);
|
||||
info.AddValue("__MethodName", this._methodName);
|
||||
info.AddValue("__MethodSignature", this._methodSignature);
|
||||
info.AddValue("__Uri", this._uri);
|
||||
info.AddValue("__Return", this._returnValue);
|
||||
info.AddValue("__OutArgs", this._args);
|
||||
}
|
||||
else
|
||||
{
|
||||
info.AddValue("__fault", this._exception);
|
||||
}
|
||||
info.AddValue("__CallContext", this._callContext);
|
||||
if (this.InternalProperties != null)
|
||||
{
|
||||
foreach (object obj in this.InternalProperties)
|
||||
{
|
||||
DictionaryEntry dictionaryEntry = (DictionaryEntry)obj;
|
||||
info.AddValue((string)dictionaryEntry.Key, dictionaryEntry.Value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Returns the specified argument marked as a ref parameter or an out parameter. </summary>
|
||||
/// <returns>The specified argument marked as a ref parameter or an out parameter.</returns>
|
||||
/// <param name="argNum">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060027BF RID: 10175 RVA: 0x000828CC File Offset: 0x00080ACC
|
||||
public object GetOutArg(int argNum)
|
||||
{
|
||||
if (this._args == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
if (this._inArgInfo == null)
|
||||
{
|
||||
this._inArgInfo = new ArgInfo(this.MethodBase, ArgInfoType.Out);
|
||||
}
|
||||
return this._args[this._inArgInfo.GetInOutArgIndex(argNum)];
|
||||
}
|
||||
|
||||
/// <summary>Returns the name of the specified argument marked as a ref parameter or an out parameter.</summary>
|
||||
/// <returns>The argument name, or null if the current method is not implemented.</returns>
|
||||
/// <param name="index">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060027C0 RID: 10176 RVA: 0x0008290C File Offset: 0x00080B0C
|
||||
public string GetOutArgName(int index)
|
||||
{
|
||||
if (this._methodBase == null)
|
||||
{
|
||||
return "__method_" + index;
|
||||
}
|
||||
if (this._inArgInfo == null)
|
||||
{
|
||||
this._inArgInfo = new ArgInfo(this.MethodBase, ArgInfoType.Out);
|
||||
}
|
||||
return this._inArgInfo.GetInOutArgName(index);
|
||||
}
|
||||
|
||||
/// <summary>Initializes an internal serialization handler from an array of remoting headers that are applied to a method. </summary>
|
||||
/// <returns>An internal serialization handler.</returns>
|
||||
/// <param name="h">An array of remoting headers that contain key/value pairs. This array is used to initialize <see cref="T:System.Runtime.Remoting.Messaging.MethodResponse" /> fields for headers that belong to the namespace "http://schemas.microsoft.com/clr/soap/messageProperties".</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060027C1 RID: 10177 RVA: 0x00082960 File Offset: 0x00080B60
|
||||
[MonoTODO]
|
||||
public virtual object HeaderHandler(Header[] h)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
/// <summary>Sets method information from serialization settings. </summary>
|
||||
/// <param name="info">The data for serializing or deserializing the remote object.</param>
|
||||
/// <param name="ctx">The context of a certain serialized stream.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.ReflectionPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="MemberAccess" />
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060027C2 RID: 10178 RVA: 0x00082968 File Offset: 0x00080B68
|
||||
[MonoTODO]
|
||||
public void RootSetObjectData(SerializationInfo info, StreamingContext ctx)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
// Token: 0x04000F62 RID: 3938
|
||||
private string _methodName;
|
||||
|
||||
// Token: 0x04000F63 RID: 3939
|
||||
private string _uri;
|
||||
|
||||
// Token: 0x04000F64 RID: 3940
|
||||
private string _typeName;
|
||||
|
||||
// Token: 0x04000F65 RID: 3941
|
||||
private MethodBase _methodBase;
|
||||
|
||||
// Token: 0x04000F66 RID: 3942
|
||||
private object _returnValue;
|
||||
|
||||
// Token: 0x04000F67 RID: 3943
|
||||
private Exception _exception;
|
||||
|
||||
// Token: 0x04000F68 RID: 3944
|
||||
private Type[] _methodSignature;
|
||||
|
||||
// Token: 0x04000F69 RID: 3945
|
||||
private ArgInfo _inArgInfo;
|
||||
|
||||
// Token: 0x04000F6A RID: 3946
|
||||
private object[] _args;
|
||||
|
||||
// Token: 0x04000F6B RID: 3947
|
||||
private object[] _outArgs;
|
||||
|
||||
// Token: 0x04000F6C RID: 3948
|
||||
private IMethodCallMessage _callMsg;
|
||||
|
||||
// Token: 0x04000F6D RID: 3949
|
||||
private LogicalCallContext _callContext;
|
||||
|
||||
// Token: 0x04000F6E RID: 3950
|
||||
private Identity _targetIdentity;
|
||||
|
||||
/// <summary>Specifies an <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties. </summary>
|
||||
// Token: 0x04000F6F RID: 3951
|
||||
protected IDictionary ExternalProperties;
|
||||
|
||||
/// <summary>Specifies an <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties. </summary>
|
||||
// Token: 0x04000F70 RID: 3952
|
||||
protected IDictionary InternalProperties;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
using System;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003FB RID: 1019
|
||||
internal class MethodReturnDictionary : MethodDictionary
|
||||
{
|
||||
// Token: 0x060027C3 RID: 10179 RVA: 0x00082970 File Offset: 0x00080B70
|
||||
public MethodReturnDictionary(IMethodReturnMessage message)
|
||||
: base(message)
|
||||
{
|
||||
if (message.Exception == null)
|
||||
{
|
||||
base.MethodKeys = MethodReturnDictionary.InternalReturnKeys;
|
||||
}
|
||||
else
|
||||
{
|
||||
base.MethodKeys = MethodReturnDictionary.InternalExceptionKeys;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000F72 RID: 3954
|
||||
public static string[] InternalReturnKeys = new string[] { "__Uri", "__MethodName", "__TypeName", "__MethodSignature", "__OutArgs", "__Return", "__CallContext" };
|
||||
|
||||
// Token: 0x04000F73 RID: 3955
|
||||
public static string[] InternalExceptionKeys = new string[] { "__CallContext" };
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,387 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Reflection;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Implements the <see cref="T:System.Runtime.Remoting.Messaging.IMethodReturnMessage" /> interface to create a message that acts as a response to a method call on a remote object.</summary>
|
||||
// Token: 0x020003FC RID: 1020
|
||||
[ComVisible(true)]
|
||||
public class MethodReturnMessageWrapper : InternalMessageWrapper, IMessage, IMethodMessage, IMethodReturnMessage
|
||||
{
|
||||
/// <summary>Wraps an <see cref="T:System.Runtime.Remoting.Messaging.IMethodReturnMessage" /> to create a <see cref="T:System.Runtime.Remoting.Messaging.MethodReturnMessageWrapper" />. </summary>
|
||||
/// <param name="msg">A message that acts as an outgoing method call on a remote object.</param>
|
||||
// Token: 0x060027C5 RID: 10181 RVA: 0x00082A10 File Offset: 0x00080C10
|
||||
public MethodReturnMessageWrapper(IMethodReturnMessage msg)
|
||||
: base(msg)
|
||||
{
|
||||
if (msg.Exception != null)
|
||||
{
|
||||
this._exception = msg.Exception;
|
||||
this._args = new object[0];
|
||||
}
|
||||
else
|
||||
{
|
||||
this._args = msg.Args;
|
||||
this._return = msg.ReturnValue;
|
||||
if (msg.MethodBase != null)
|
||||
{
|
||||
this._outArgInfo = new ArgInfo(msg.MethodBase, ArgInfoType.Out);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the number of arguments passed to the method. </summary>
|
||||
/// <returns>A <see cref="T:System.Int32" /> that represents the number of arguments passed to a method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007B1 RID: 1969
|
||||
// (get) Token: 0x060027C6 RID: 10182 RVA: 0x00082A84 File Offset: 0x00080C84
|
||||
public virtual int ArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._args.Length;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an array of arguments passed to the method. </summary>
|
||||
/// <returns>An array of type <see cref="T:System.Object" /> that represents the arguments passed to a method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007B2 RID: 1970
|
||||
// (get) Token: 0x060027C7 RID: 10183 RVA: 0x00082A90 File Offset: 0x00080C90
|
||||
// (set) Token: 0x060027C8 RID: 10184 RVA: 0x00082A98 File Offset: 0x00080C98
|
||||
public virtual object[] Args
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._args;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._args = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the exception thrown during the method call, or null if the method did not throw an exception. </summary>
|
||||
/// <returns>The <see cref="T:System.Exception" /> thrown during the method call, or null if the method did not throw an exception.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007B3 RID: 1971
|
||||
// (get) Token: 0x060027C9 RID: 10185 RVA: 0x00082AA4 File Offset: 0x00080CA4
|
||||
// (set) Token: 0x060027CA RID: 10186 RVA: 0x00082AAC File Offset: 0x00080CAC
|
||||
public virtual Exception Exception
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._exception;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._exception = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a flag that indicates whether the method can accept a variable number of arguments. </summary>
|
||||
/// <returns>true if the method can accept a variable number of arguments; otherwise, false.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007B4 RID: 1972
|
||||
// (get) Token: 0x060027CB RID: 10187 RVA: 0x00082AB8 File Offset: 0x00080CB8
|
||||
public virtual bool HasVarArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodReturnMessage)this.WrappedMessage).HasVarArgs;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> for the current method call. </summary>
|
||||
/// <returns>The <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> for the current method call.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007B5 RID: 1973
|
||||
// (get) Token: 0x060027CC RID: 10188 RVA: 0x00082ACC File Offset: 0x00080CCC
|
||||
public virtual LogicalCallContext LogicalCallContext
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodReturnMessage)this.WrappedMessage).LogicalCallContext;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Reflection.MethodBase" /> of the called method. </summary>
|
||||
/// <returns>The <see cref="T:System.Reflection.MethodBase" /> of the called method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007B6 RID: 1974
|
||||
// (get) Token: 0x060027CD RID: 10189 RVA: 0x00082AE0 File Offset: 0x00080CE0
|
||||
public virtual MethodBase MethodBase
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodReturnMessage)this.WrappedMessage).MethodBase;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the name of the invoked method. </summary>
|
||||
/// <returns>A <see cref="T:System.String" /> that contains the name of the invoked method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007B7 RID: 1975
|
||||
// (get) Token: 0x060027CE RID: 10190 RVA: 0x00082AF4 File Offset: 0x00080CF4
|
||||
public virtual string MethodName
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodReturnMessage)this.WrappedMessage).MethodName;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an object that contains the method signature. </summary>
|
||||
/// <returns>A <see cref="T:System.Object" /> that contains the method signature.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007B8 RID: 1976
|
||||
// (get) Token: 0x060027CF RID: 10191 RVA: 0x00082B08 File Offset: 0x00080D08
|
||||
public virtual object MethodSignature
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodReturnMessage)this.WrappedMessage).MethodSignature;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the number of arguments in the method call that are marked as ref parameters or out parameters. </summary>
|
||||
/// <returns>A <see cref="T:System.Int32" /> that represents the number of arguments in the method call that are marked as ref parameters or out parameters.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007B9 RID: 1977
|
||||
// (get) Token: 0x060027D0 RID: 10192 RVA: 0x00082B1C File Offset: 0x00080D1C
|
||||
public virtual int OutArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return (this._outArgInfo == null) ? 0 : this._outArgInfo.GetInOutArgCount();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an array of arguments in the method call that are marked as ref parameters or out parameters. </summary>
|
||||
/// <returns>An array of type <see cref="T:System.Object" /> that represents the arguments in the method call that are marked as ref parameters or out parameters.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007BA RID: 1978
|
||||
// (get) Token: 0x060027D1 RID: 10193 RVA: 0x00082B3C File Offset: 0x00080D3C
|
||||
public virtual object[] OutArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
return (this._outArgInfo == null) ? this._args : this._outArgInfo.GetInOutArgs(this._args);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>An <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties. </summary>
|
||||
/// <returns>An <see cref="T:System.Collections.IDictionary" /> interface that represents a collection of the remoting message's properties.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007BB RID: 1979
|
||||
// (get) Token: 0x060027D2 RID: 10194 RVA: 0x00082B68 File Offset: 0x00080D68
|
||||
public virtual IDictionary Properties
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._properties == null)
|
||||
{
|
||||
this._properties = new MethodReturnMessageWrapper.DictionaryWrapper(this, this.WrappedMessage.Properties);
|
||||
}
|
||||
return this._properties;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the return value of the method call. </summary>
|
||||
/// <returns>A <see cref="T:System.Object" /> that represents the return value of the method call.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007BC RID: 1980
|
||||
// (get) Token: 0x060027D3 RID: 10195 RVA: 0x00082BA0 File Offset: 0x00080DA0
|
||||
// (set) Token: 0x060027D4 RID: 10196 RVA: 0x00082BA8 File Offset: 0x00080DA8
|
||||
public virtual object ReturnValue
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._return;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._return = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the full type name of the remote object on which the method call is being made. </summary>
|
||||
/// <returns>A <see cref="T:System.String" /> that contains the full type name of the remote object on which the method call is being made.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007BD RID: 1981
|
||||
// (get) Token: 0x060027D5 RID: 10197 RVA: 0x00082BB4 File Offset: 0x00080DB4
|
||||
public virtual string TypeName
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodReturnMessage)this.WrappedMessage).TypeName;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the Uniform Resource Identifier (URI) of the remote object on which the method call is being made. </summary>
|
||||
/// <returns>The URI of a remote object.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007BE RID: 1982
|
||||
// (get) Token: 0x060027D6 RID: 10198 RVA: 0x00082BC8 File Offset: 0x00080DC8
|
||||
// (set) Token: 0x060027D7 RID: 10199 RVA: 0x00082BDC File Offset: 0x00080DDC
|
||||
public string Uri
|
||||
{
|
||||
get
|
||||
{
|
||||
return ((IMethodReturnMessage)this.WrappedMessage).Uri;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.Properties["__Uri"] = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a method argument, as an object, at a specified index. </summary>
|
||||
/// <returns>The method argument as an object.</returns>
|
||||
/// <param name="argNum">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060027D8 RID: 10200 RVA: 0x00082BF0 File Offset: 0x00080DF0
|
||||
public virtual object GetArg(int argNum)
|
||||
{
|
||||
return this._args[argNum];
|
||||
}
|
||||
|
||||
/// <summary>Gets the name of a method argument at a specified index. </summary>
|
||||
/// <returns>The name of the method argument.</returns>
|
||||
/// <param name="index">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060027D9 RID: 10201 RVA: 0x00082BFC File Offset: 0x00080DFC
|
||||
public virtual string GetArgName(int index)
|
||||
{
|
||||
return ((IMethodReturnMessage)this.WrappedMessage).GetArgName(index);
|
||||
}
|
||||
|
||||
/// <summary>Returns the specified argument marked as a ref parameter or an out parameter. </summary>
|
||||
/// <returns>The specified argument marked as a ref parameter or an out parameter.</returns>
|
||||
/// <param name="argNum">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060027DA RID: 10202 RVA: 0x00082C10 File Offset: 0x00080E10
|
||||
public virtual object GetOutArg(int argNum)
|
||||
{
|
||||
return this._args[this._outArgInfo.GetInOutArgIndex(argNum)];
|
||||
}
|
||||
|
||||
/// <summary>Returns the name of the specified argument marked as a ref parameter or an out parameter. </summary>
|
||||
/// <returns>The argument name, or null if the current method is not implemented.</returns>
|
||||
/// <param name="index">The index of the requested argument.</param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x060027DB RID: 10203 RVA: 0x00082C28 File Offset: 0x00080E28
|
||||
public virtual string GetOutArgName(int index)
|
||||
{
|
||||
return this._outArgInfo.GetInOutArgName(index);
|
||||
}
|
||||
|
||||
// Token: 0x04000F74 RID: 3956
|
||||
private object[] _args;
|
||||
|
||||
// Token: 0x04000F75 RID: 3957
|
||||
private ArgInfo _outArgInfo;
|
||||
|
||||
// Token: 0x04000F76 RID: 3958
|
||||
private MethodReturnMessageWrapper.DictionaryWrapper _properties;
|
||||
|
||||
// Token: 0x04000F77 RID: 3959
|
||||
private Exception _exception;
|
||||
|
||||
// Token: 0x04000F78 RID: 3960
|
||||
private object _return;
|
||||
|
||||
// Token: 0x020003FD RID: 1021
|
||||
private class DictionaryWrapper : MethodReturnDictionary
|
||||
{
|
||||
// Token: 0x060027DC RID: 10204 RVA: 0x00082C38 File Offset: 0x00080E38
|
||||
public DictionaryWrapper(IMethodReturnMessage message, IDictionary wrappedDictionary)
|
||||
: base(message)
|
||||
{
|
||||
this._wrappedDictionary = wrappedDictionary;
|
||||
base.MethodKeys = MethodReturnMessageWrapper.DictionaryWrapper._keys;
|
||||
}
|
||||
|
||||
// Token: 0x060027DE RID: 10206 RVA: 0x00082C74 File Offset: 0x00080E74
|
||||
protected override IDictionary AllocInternalProperties()
|
||||
{
|
||||
return this._wrappedDictionary;
|
||||
}
|
||||
|
||||
// Token: 0x060027DF RID: 10207 RVA: 0x00082C7C File Offset: 0x00080E7C
|
||||
protected override void SetMethodProperty(string key, object value)
|
||||
{
|
||||
if (key == "__Args")
|
||||
{
|
||||
((MethodReturnMessageWrapper)this._message)._args = (object[])value;
|
||||
}
|
||||
else if (key == "__Return")
|
||||
{
|
||||
((MethodReturnMessageWrapper)this._message)._return = value;
|
||||
}
|
||||
else
|
||||
{
|
||||
base.SetMethodProperty(key, value);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060027E0 RID: 10208 RVA: 0x00082CE4 File Offset: 0x00080EE4
|
||||
protected override object GetMethodProperty(string key)
|
||||
{
|
||||
if (key == "__Args")
|
||||
{
|
||||
return ((MethodReturnMessageWrapper)this._message)._args;
|
||||
}
|
||||
if (key == "__Return")
|
||||
{
|
||||
return ((MethodReturnMessageWrapper)this._message)._return;
|
||||
}
|
||||
return base.GetMethodProperty(key);
|
||||
}
|
||||
|
||||
// Token: 0x04000F79 RID: 3961
|
||||
private IDictionary _wrappedDictionary;
|
||||
|
||||
// Token: 0x04000F7A RID: 3962
|
||||
private static string[] _keys = new string[] { "__Args", "__Return" };
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,487 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x020003FE RID: 1022
|
||||
[Serializable]
|
||||
internal class MonoMethodMessage : IInternalMessage, IMessage, IMethodCallMessage, IMethodMessage, IMethodReturnMessage
|
||||
{
|
||||
// Token: 0x060027E1 RID: 10209 RVA: 0x00082D3C File Offset: 0x00080F3C
|
||||
public MonoMethodMessage(MethodBase method, object[] out_args)
|
||||
{
|
||||
if (method != null)
|
||||
{
|
||||
this.InitMessage((MonoMethod)method, out_args);
|
||||
}
|
||||
else
|
||||
{
|
||||
this.args = null;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060027E2 RID: 10210 RVA: 0x00082D64 File Offset: 0x00080F64
|
||||
public MonoMethodMessage(Type type, string method_name, object[] in_args)
|
||||
{
|
||||
MethodInfo methodInfo = type.GetMethod(method_name);
|
||||
this.InitMessage((MonoMethod)methodInfo, null);
|
||||
int num = in_args.Length;
|
||||
for (int i = 0; i < num; i++)
|
||||
{
|
||||
this.args[i] = in_args[i];
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007BF RID: 1983
|
||||
// (get) Token: 0x060027E3 RID: 10211 RVA: 0x00082DB0 File Offset: 0x00080FB0
|
||||
// (set) Token: 0x060027E4 RID: 10212 RVA: 0x00082DB8 File Offset: 0x00080FB8
|
||||
Identity IInternalMessage.TargetIdentity
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.identity;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.identity = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060027E5 RID: 10213
|
||||
[MethodImpl(MethodImplOptions.InternalCall)]
|
||||
internal extern void InitMessage(MonoMethod method, object[] out_args);
|
||||
|
||||
// Token: 0x170007C0 RID: 1984
|
||||
// (get) Token: 0x060027E6 RID: 10214 RVA: 0x00082DC4 File Offset: 0x00080FC4
|
||||
public IDictionary Properties
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.properties == null)
|
||||
{
|
||||
this.properties = new MethodCallDictionary(this);
|
||||
}
|
||||
return this.properties;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007C1 RID: 1985
|
||||
// (get) Token: 0x060027E7 RID: 10215 RVA: 0x00082DE4 File Offset: 0x00080FE4
|
||||
public int ArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.CallType == CallType.EndInvoke)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
if (this.args == null)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
return this.args.Length;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007C2 RID: 1986
|
||||
// (get) Token: 0x060027E8 RID: 10216 RVA: 0x00082E0C File Offset: 0x0008100C
|
||||
public object[] Args
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.args;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007C3 RID: 1987
|
||||
// (get) Token: 0x060027E9 RID: 10217 RVA: 0x00082E14 File Offset: 0x00081014
|
||||
public bool HasVarArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007C4 RID: 1988
|
||||
// (get) Token: 0x060027EA RID: 10218 RVA: 0x00082E18 File Offset: 0x00081018
|
||||
// (set) Token: 0x060027EB RID: 10219 RVA: 0x00082E20 File Offset: 0x00081020
|
||||
public LogicalCallContext LogicalCallContext
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.ctx;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.ctx = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007C5 RID: 1989
|
||||
// (get) Token: 0x060027EC RID: 10220 RVA: 0x00082E2C File Offset: 0x0008102C
|
||||
public MethodBase MethodBase
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.method;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007C6 RID: 1990
|
||||
// (get) Token: 0x060027ED RID: 10221 RVA: 0x00082E34 File Offset: 0x00081034
|
||||
public string MethodName
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.method == null)
|
||||
{
|
||||
return string.Empty;
|
||||
}
|
||||
return this.method.Name;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007C7 RID: 1991
|
||||
// (get) Token: 0x060027EE RID: 10222 RVA: 0x00082E54 File Offset: 0x00081054
|
||||
public object MethodSignature
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.methodSignature == null)
|
||||
{
|
||||
ParameterInfo[] parameters = this.method.GetParameters();
|
||||
this.methodSignature = new Type[parameters.Length];
|
||||
for (int i = 0; i < parameters.Length; i++)
|
||||
{
|
||||
this.methodSignature[i] = parameters[i].ParameterType;
|
||||
}
|
||||
}
|
||||
return this.methodSignature;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007C8 RID: 1992
|
||||
// (get) Token: 0x060027EF RID: 10223 RVA: 0x00082EB0 File Offset: 0x000810B0
|
||||
public string TypeName
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.method == null)
|
||||
{
|
||||
return string.Empty;
|
||||
}
|
||||
return this.method.DeclaringType.AssemblyQualifiedName;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007C9 RID: 1993
|
||||
// (get) Token: 0x060027F0 RID: 10224 RVA: 0x00082ED4 File Offset: 0x000810D4
|
||||
// (set) Token: 0x060027F1 RID: 10225 RVA: 0x00082EDC File Offset: 0x000810DC
|
||||
public string Uri
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.uri;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.uri = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060027F2 RID: 10226 RVA: 0x00082EE8 File Offset: 0x000810E8
|
||||
public object GetArg(int arg_num)
|
||||
{
|
||||
if (this.args == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return this.args[arg_num];
|
||||
}
|
||||
|
||||
// Token: 0x060027F3 RID: 10227 RVA: 0x00082F00 File Offset: 0x00081100
|
||||
public string GetArgName(int arg_num)
|
||||
{
|
||||
if (this.args == null)
|
||||
{
|
||||
return string.Empty;
|
||||
}
|
||||
return this.names[arg_num];
|
||||
}
|
||||
|
||||
// Token: 0x170007CA RID: 1994
|
||||
// (get) Token: 0x060027F4 RID: 10228 RVA: 0x00082F1C File Offset: 0x0008111C
|
||||
public int InArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.CallType == CallType.EndInvoke)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
if (this.args == null)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
int num = 0;
|
||||
foreach (byte b in this.arg_types)
|
||||
{
|
||||
if ((b & 1) != 0)
|
||||
{
|
||||
num++;
|
||||
}
|
||||
}
|
||||
return num;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007CB RID: 1995
|
||||
// (get) Token: 0x060027F5 RID: 10229 RVA: 0x00082F74 File Offset: 0x00081174
|
||||
public object[] InArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
int inArgCount = this.InArgCount;
|
||||
object[] array = new object[inArgCount];
|
||||
int num2;
|
||||
int num = (num2 = 0);
|
||||
foreach (byte b in this.arg_types)
|
||||
{
|
||||
if ((b & 1) != 0)
|
||||
{
|
||||
array[num++] = this.args[num2];
|
||||
}
|
||||
num2++;
|
||||
}
|
||||
return array;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060027F6 RID: 10230 RVA: 0x00082FD8 File Offset: 0x000811D8
|
||||
public object GetInArg(int arg_num)
|
||||
{
|
||||
int num = 0;
|
||||
int num2 = 0;
|
||||
foreach (byte b in this.arg_types)
|
||||
{
|
||||
if ((b & 1) != 0 && num2++ == arg_num)
|
||||
{
|
||||
return this.args[num];
|
||||
}
|
||||
num++;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
// Token: 0x060027F7 RID: 10231 RVA: 0x00083030 File Offset: 0x00081230
|
||||
public string GetInArgName(int arg_num)
|
||||
{
|
||||
int num = 0;
|
||||
int num2 = 0;
|
||||
foreach (byte b in this.arg_types)
|
||||
{
|
||||
if ((b & 1) != 0 && num2++ == arg_num)
|
||||
{
|
||||
return this.names[num];
|
||||
}
|
||||
num++;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
// Token: 0x170007CC RID: 1996
|
||||
// (get) Token: 0x060027F8 RID: 10232 RVA: 0x00083088 File Offset: 0x00081288
|
||||
public Exception Exception
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.exc;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007CD RID: 1997
|
||||
// (get) Token: 0x060027F9 RID: 10233 RVA: 0x00083090 File Offset: 0x00081290
|
||||
public int OutArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.args == null)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
int num = 0;
|
||||
foreach (byte b in this.arg_types)
|
||||
{
|
||||
if ((b & 2) != 0)
|
||||
{
|
||||
num++;
|
||||
}
|
||||
}
|
||||
return num;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007CE RID: 1998
|
||||
// (get) Token: 0x060027FA RID: 10234 RVA: 0x000830D8 File Offset: 0x000812D8
|
||||
public object[] OutArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.args == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
int outArgCount = this.OutArgCount;
|
||||
object[] array = new object[outArgCount];
|
||||
int num2;
|
||||
int num = (num2 = 0);
|
||||
foreach (byte b in this.arg_types)
|
||||
{
|
||||
if ((b & 2) != 0)
|
||||
{
|
||||
array[num++] = this.args[num2];
|
||||
}
|
||||
num2++;
|
||||
}
|
||||
return array;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007CF RID: 1999
|
||||
// (get) Token: 0x060027FB RID: 10235 RVA: 0x0008314C File Offset: 0x0008134C
|
||||
public object ReturnValue
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.rval;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x060027FC RID: 10236 RVA: 0x00083154 File Offset: 0x00081354
|
||||
public object GetOutArg(int arg_num)
|
||||
{
|
||||
int num = 0;
|
||||
int num2 = 0;
|
||||
foreach (byte b in this.arg_types)
|
||||
{
|
||||
if ((b & 2) != 0 && num2++ == arg_num)
|
||||
{
|
||||
return this.args[num];
|
||||
}
|
||||
num++;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
// Token: 0x060027FD RID: 10237 RVA: 0x000831AC File Offset: 0x000813AC
|
||||
public string GetOutArgName(int arg_num)
|
||||
{
|
||||
int num = 0;
|
||||
int num2 = 0;
|
||||
foreach (byte b in this.arg_types)
|
||||
{
|
||||
if ((b & 2) != 0 && num2++ == arg_num)
|
||||
{
|
||||
return this.names[num];
|
||||
}
|
||||
num++;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
// Token: 0x170007D0 RID: 2000
|
||||
// (get) Token: 0x060027FE RID: 10238 RVA: 0x00083204 File Offset: 0x00081404
|
||||
public bool IsAsync
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.asyncResult != null;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007D1 RID: 2001
|
||||
// (get) Token: 0x060027FF RID: 10239 RVA: 0x00083214 File Offset: 0x00081414
|
||||
public AsyncResult AsyncResult
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.asyncResult;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007D2 RID: 2002
|
||||
// (get) Token: 0x06002800 RID: 10240 RVA: 0x0008321C File Offset: 0x0008141C
|
||||
internal CallType CallType
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.call_type == CallType.Sync && RemotingServices.IsOneWay(this.method))
|
||||
{
|
||||
this.call_type = CallType.OneWay;
|
||||
}
|
||||
return this.call_type;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002801 RID: 10241 RVA: 0x00083254 File Offset: 0x00081454
|
||||
public bool NeedsOutProcessing(out int outCount)
|
||||
{
|
||||
bool flag = false;
|
||||
outCount = 0;
|
||||
foreach (byte b in this.arg_types)
|
||||
{
|
||||
if ((b & 2) != 0)
|
||||
{
|
||||
outCount++;
|
||||
}
|
||||
else if ((b & 4) != 0)
|
||||
{
|
||||
flag = true;
|
||||
}
|
||||
}
|
||||
return outCount > 0 || flag;
|
||||
}
|
||||
|
||||
// Token: 0x04000F7B RID: 3963
|
||||
private MonoMethod method;
|
||||
|
||||
// Token: 0x04000F7C RID: 3964
|
||||
private object[] args;
|
||||
|
||||
// Token: 0x04000F7D RID: 3965
|
||||
private string[] names;
|
||||
|
||||
// Token: 0x04000F7E RID: 3966
|
||||
private byte[] arg_types;
|
||||
|
||||
// Token: 0x04000F7F RID: 3967
|
||||
public LogicalCallContext ctx;
|
||||
|
||||
// Token: 0x04000F80 RID: 3968
|
||||
public object rval;
|
||||
|
||||
// Token: 0x04000F81 RID: 3969
|
||||
public Exception exc;
|
||||
|
||||
// Token: 0x04000F82 RID: 3970
|
||||
private AsyncResult asyncResult;
|
||||
|
||||
// Token: 0x04000F83 RID: 3971
|
||||
private CallType call_type;
|
||||
|
||||
// Token: 0x04000F84 RID: 3972
|
||||
private string uri;
|
||||
|
||||
// Token: 0x04000F85 RID: 3973
|
||||
private MethodCallDictionary properties;
|
||||
|
||||
// Token: 0x04000F86 RID: 3974
|
||||
private Type[] methodSignature;
|
||||
|
||||
// Token: 0x04000F87 RID: 3975
|
||||
private Identity identity;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
using System;
|
||||
using System.Runtime.Serialization;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x02000402 RID: 1026
|
||||
internal class ObjRefSurrogate : ISerializationSurrogate
|
||||
{
|
||||
// Token: 0x06002807 RID: 10247 RVA: 0x00083318 File Offset: 0x00081518
|
||||
public virtual void GetObjectData(object obj, SerializationInfo si, StreamingContext sc)
|
||||
{
|
||||
if (obj == null || si == null)
|
||||
{
|
||||
throw new ArgumentNullException();
|
||||
}
|
||||
((ObjRef)obj).GetObjectData(si, sc);
|
||||
si.AddValue("fIsMarshalled", 0);
|
||||
}
|
||||
|
||||
// Token: 0x06002808 RID: 10248 RVA: 0x00083348 File Offset: 0x00081548
|
||||
public virtual object SetObjectData(object obj, SerializationInfo si, StreamingContext sc, ISurrogateSelector selector)
|
||||
{
|
||||
throw new NotSupportedException("Do not use RemotingSurrogateSelector when deserializating");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Marks a method as one way, without a return value and out or ref parameters.</summary>
|
||||
// Token: 0x02000400 RID: 1024
|
||||
[AttributeUsage(AttributeTargets.Method)]
|
||||
[ComVisible(true)]
|
||||
public class OneWayAttribute : Attribute
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
using System;
|
||||
using System.Runtime.Remoting.Proxies;
|
||||
using System.Runtime.Serialization;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x02000401 RID: 1025
|
||||
internal class RemotingSurrogate : ISerializationSurrogate
|
||||
{
|
||||
// Token: 0x06002804 RID: 10244 RVA: 0x000832C0 File Offset: 0x000814C0
|
||||
public virtual void GetObjectData(object obj, SerializationInfo si, StreamingContext sc)
|
||||
{
|
||||
if (obj == null || si == null)
|
||||
{
|
||||
throw new ArgumentNullException();
|
||||
}
|
||||
if (RemotingServices.IsTransparentProxy(obj))
|
||||
{
|
||||
RealProxy realProxy = RemotingServices.GetRealProxy(obj);
|
||||
realProxy.GetObjectData(si, sc);
|
||||
}
|
||||
else
|
||||
{
|
||||
RemotingServices.GetObjectData(obj, si, sc);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002805 RID: 10245 RVA: 0x00083308 File Offset: 0x00081508
|
||||
public virtual object SetObjectData(object obj, SerializationInfo si, StreamingContext sc, ISurrogateSelector selector)
|
||||
{
|
||||
throw new NotSupportedException();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,137 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Runtime.Serialization;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Selects the remoting surrogate that can be used to serialize an object that derives from a <see cref="T:System.MarshalByRefObject" />.</summary>
|
||||
// Token: 0x02000403 RID: 1027
|
||||
[ComVisible(true)]
|
||||
public class RemotingSurrogateSelector : ISurrogateSelector
|
||||
{
|
||||
/// <summary>Gets or sets the <see cref="T:System.Runtime.Remoting.Messaging.MessageSurrogateFilter" /> delegate for the current instance of the <see cref="T:System.Runtime.Remoting.Messaging.RemotingSurrogateSelector" />.</summary>
|
||||
/// <returns>The <see cref="T:System.Runtime.Remoting.Messaging.MessageSurrogateFilter" /> delegate for the current instance of the <see cref="T:System.Runtime.Remoting.Messaging.RemotingSurrogateSelector" />.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007D3 RID: 2003
|
||||
// (get) Token: 0x0600280B RID: 10251 RVA: 0x00083384 File Offset: 0x00081584
|
||||
// (set) Token: 0x0600280C RID: 10252 RVA: 0x0008338C File Offset: 0x0008158C
|
||||
public MessageSurrogateFilter Filter
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._filter;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._filter = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Adds the specified <see cref="T:System.Runtime.Serialization.ISurrogateSelector" /> to the surrogate selector chain.</summary>
|
||||
/// <param name="selector">The next <see cref="T:System.Runtime.Serialization.ISurrogateSelector" /> to examine. </param>
|
||||
// Token: 0x0600280D RID: 10253 RVA: 0x00083398 File Offset: 0x00081598
|
||||
public virtual void ChainSelector(ISurrogateSelector selector)
|
||||
{
|
||||
if (this._next != null)
|
||||
{
|
||||
selector.ChainSelector(this._next);
|
||||
}
|
||||
this._next = selector;
|
||||
}
|
||||
|
||||
/// <summary>Returns the next <see cref="T:System.Runtime.Serialization.ISurrogateSelector" /> in the chain of surrogate selectors.</summary>
|
||||
/// <returns>The next <see cref="T:System.Runtime.Serialization.ISurrogateSelector" /> in the chain of surrogate selectors.</returns>
|
||||
// Token: 0x0600280E RID: 10254 RVA: 0x000833B8 File Offset: 0x000815B8
|
||||
public virtual ISurrogateSelector GetNextSelector()
|
||||
{
|
||||
return this._next;
|
||||
}
|
||||
|
||||
/// <summary>Returns the object at the root of the object graph.</summary>
|
||||
/// <returns>The object at the root of the object graph.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x0600280F RID: 10255 RVA: 0x000833C0 File Offset: 0x000815C0
|
||||
public object GetRootObject()
|
||||
{
|
||||
return this._rootObj;
|
||||
}
|
||||
|
||||
/// <summary>Returns the appropriate surrogate for the given type in the given context.</summary>
|
||||
/// <returns>The appropriate surrogate for the given type in the given context.</returns>
|
||||
/// <param name="type">The <see cref="T:System.Type" /> for which the surrogate is requested. </param>
|
||||
/// <param name="context">The source or destination of serialization. </param>
|
||||
/// <param name="ssout">When this method returns, contains an <see cref="T:System.Runtime.Serialization.ISurrogateSelector" /> that is appropriate for the specified object type. This parameter is passed uninitialized. </param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="SerializationFormatter, Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002810 RID: 10256 RVA: 0x000833C8 File Offset: 0x000815C8
|
||||
public virtual ISerializationSurrogate GetSurrogate(Type type, StreamingContext context, out ISurrogateSelector ssout)
|
||||
{
|
||||
if (type.IsMarshalByRef)
|
||||
{
|
||||
ssout = this;
|
||||
return RemotingSurrogateSelector._objRemotingSurrogate;
|
||||
}
|
||||
if (RemotingSurrogateSelector.s_cachedTypeObjRef.IsAssignableFrom(type))
|
||||
{
|
||||
ssout = this;
|
||||
return RemotingSurrogateSelector._objRefSurrogate;
|
||||
}
|
||||
if (this._next != null)
|
||||
{
|
||||
return this._next.GetSurrogate(type, context, out ssout);
|
||||
}
|
||||
ssout = null;
|
||||
return null;
|
||||
}
|
||||
|
||||
/// <summary>Sets the object at the root of the object graph.</summary>
|
||||
/// <param name="obj">The object at the root of the object graph. </param>
|
||||
/// <exception cref="T:System.ArgumentNullException">The <paramref name="obj" /> parameter is null. </exception>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002811 RID: 10257 RVA: 0x00083420 File Offset: 0x00081620
|
||||
public void SetRootObject(object obj)
|
||||
{
|
||||
if (obj == null)
|
||||
{
|
||||
throw new ArgumentNullException();
|
||||
}
|
||||
this._rootObj = obj;
|
||||
}
|
||||
|
||||
/// <summary>Sets up the current surrogate selector to use the SOAP format.</summary>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002812 RID: 10258 RVA: 0x00083438 File Offset: 0x00081638
|
||||
[MonoTODO]
|
||||
public virtual void UseSoapFormat()
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
// Token: 0x04000F8D RID: 3981
|
||||
private static Type s_cachedTypeObjRef = typeof(ObjRef);
|
||||
|
||||
// Token: 0x04000F8E RID: 3982
|
||||
private static ObjRefSurrogate _objRefSurrogate = new ObjRefSurrogate();
|
||||
|
||||
// Token: 0x04000F8F RID: 3983
|
||||
private static RemotingSurrogate _objRemotingSurrogate = new RemotingSurrogate();
|
||||
|
||||
// Token: 0x04000F90 RID: 3984
|
||||
private object _rootObj;
|
||||
|
||||
// Token: 0x04000F91 RID: 3985
|
||||
private MessageSurrogateFilter _filter;
|
||||
|
||||
// Token: 0x04000F92 RID: 3986
|
||||
private ISurrogateSelector _next;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,436 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Reflection;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
/// <summary>Holds a message returned in response to a method call on a remote object.</summary>
|
||||
// Token: 0x02000404 RID: 1028
|
||||
[ComVisible(true)]
|
||||
public class ReturnMessage : IInternalMessage, IMessage, IMethodMessage, IMethodReturnMessage
|
||||
{
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.ReturnMessage" /> class with all the information returning to the caller after the method call.</summary>
|
||||
/// <param name="ret">The object returned by the invoked method from which the current <see cref="T:System.Runtime.Remoting.Messaging.ReturnMessage" /> instance originated. </param>
|
||||
/// <param name="outArgs">The objects returned from the invoked method as out parameters. </param>
|
||||
/// <param name="outArgsCount">The number of out parameters returned from the invoked method. </param>
|
||||
/// <param name="callCtx">The <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> of the method call. </param>
|
||||
/// <param name="mcm">The original method call to the invoked method. </param>
|
||||
// Token: 0x06002813 RID: 10259 RVA: 0x00083440 File Offset: 0x00081640
|
||||
public ReturnMessage(object ret, object[] outArgs, int outArgsCount, LogicalCallContext callCtx, IMethodCallMessage mcm)
|
||||
{
|
||||
this._returnValue = ret;
|
||||
this._args = outArgs;
|
||||
this._outArgsCount = outArgsCount;
|
||||
this._callCtx = callCtx;
|
||||
if (mcm != null)
|
||||
{
|
||||
this._uri = mcm.Uri;
|
||||
this._methodBase = mcm.MethodBase;
|
||||
}
|
||||
if (this._args == null)
|
||||
{
|
||||
this._args = new object[outArgsCount];
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Initializes a new instance of the <see cref="T:System.Runtime.Remoting.Messaging.ReturnMessage" /> class.</summary>
|
||||
/// <param name="e">The exception that was thrown during execution of the remotely called method. </param>
|
||||
/// <param name="mcm">An <see cref="T:System.Runtime.Remoting.Messaging.IMethodCallMessage" /> with which to create an instance of the <see cref="T:System.Runtime.Remoting.Messaging.ReturnMessage" /> class. </param>
|
||||
// Token: 0x06002814 RID: 10260 RVA: 0x000834A8 File Offset: 0x000816A8
|
||||
public ReturnMessage(Exception e, IMethodCallMessage mcm)
|
||||
{
|
||||
this._exception = e;
|
||||
if (mcm != null)
|
||||
{
|
||||
this._methodBase = mcm.MethodBase;
|
||||
this._callCtx = mcm.LogicalCallContext;
|
||||
}
|
||||
this._args = new object[0];
|
||||
}
|
||||
|
||||
// Token: 0x170007D4 RID: 2004
|
||||
// (get) Token: 0x06002815 RID: 10261 RVA: 0x000834EC File Offset: 0x000816EC
|
||||
// (set) Token: 0x06002816 RID: 10262 RVA: 0x000834F4 File Offset: 0x000816F4
|
||||
string IInternalMessage.Uri
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.Uri;
|
||||
}
|
||||
set
|
||||
{
|
||||
this.Uri = value;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x170007D5 RID: 2005
|
||||
// (get) Token: 0x06002817 RID: 10263 RVA: 0x00083500 File Offset: 0x00081700
|
||||
// (set) Token: 0x06002818 RID: 10264 RVA: 0x00083508 File Offset: 0x00081708
|
||||
Identity IInternalMessage.TargetIdentity
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._targetIdentity;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._targetIdentity = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the number of arguments of the called method.</summary>
|
||||
/// <returns>The number of arguments of the called method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007D6 RID: 2006
|
||||
// (get) Token: 0x06002819 RID: 10265 RVA: 0x00083514 File Offset: 0x00081714
|
||||
public int ArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._args.Length;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a specified argument passed to the method called on the remote object.</summary>
|
||||
/// <returns>An argument passed to the method called on the remote object.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007D7 RID: 2007
|
||||
// (get) Token: 0x0600281A RID: 10266 RVA: 0x00083520 File Offset: 0x00081720
|
||||
public object[] Args
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._args;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a value indicating whether the called method accepts a variable number of arguments.</summary>
|
||||
/// <returns>true if the called method accepts a variable number of arguments; otherwise, false.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007D8 RID: 2008
|
||||
// (get) Token: 0x0600281B RID: 10267 RVA: 0x00083528 File Offset: 0x00081728
|
||||
public bool HasVarArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._methodBase != null && (this._methodBase.CallingConvention | CallingConventions.VarArgs) != (CallingConventions)0;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> of the called method.</summary>
|
||||
/// <returns>The <see cref="T:System.Runtime.Remoting.Messaging.LogicalCallContext" /> of the called method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007D9 RID: 2009
|
||||
// (get) Token: 0x0600281C RID: 10268 RVA: 0x00083558 File Offset: 0x00081758
|
||||
public LogicalCallContext LogicalCallContext
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._callCtx == null)
|
||||
{
|
||||
this._callCtx = new LogicalCallContext();
|
||||
}
|
||||
return this._callCtx;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the <see cref="T:System.Reflection.MethodBase" /> of the called method.</summary>
|
||||
/// <returns>The <see cref="T:System.Reflection.MethodBase" /> of the called method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007DA RID: 2010
|
||||
// (get) Token: 0x0600281D RID: 10269 RVA: 0x00083578 File Offset: 0x00081778
|
||||
public MethodBase MethodBase
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._methodBase;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the name of the called method.</summary>
|
||||
/// <returns>The name of the method that the current <see cref="T:System.Runtime.Remoting.Messaging.ReturnMessage" /> originated from.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007DB RID: 2011
|
||||
// (get) Token: 0x0600281E RID: 10270 RVA: 0x00083580 File Offset: 0x00081780
|
||||
public string MethodName
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._methodBase != null && this._methodName == null)
|
||||
{
|
||||
this._methodName = this._methodBase.Name;
|
||||
}
|
||||
return this._methodName;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an array of <see cref="T:System.Type" /> objects containing the method signature.</summary>
|
||||
/// <returns>An array of <see cref="T:System.Type" /> objects containing the method signature.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007DC RID: 2012
|
||||
// (get) Token: 0x0600281F RID: 10271 RVA: 0x000835B0 File Offset: 0x000817B0
|
||||
public object MethodSignature
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._methodBase != null && this._methodSignature == null)
|
||||
{
|
||||
ParameterInfo[] parameters = this._methodBase.GetParameters();
|
||||
this._methodSignature = new Type[parameters.Length];
|
||||
for (int i = 0; i < parameters.Length; i++)
|
||||
{
|
||||
this._methodSignature[i] = parameters[i].ParameterType;
|
||||
}
|
||||
}
|
||||
return this._methodSignature;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets an <see cref="T:System.Collections.IDictionary" /> of properties contained in the current <see cref="T:System.Runtime.Remoting.Messaging.ReturnMessage" />.</summary>
|
||||
/// <returns>An <see cref="T:System.Collections.IDictionary" /> of properties contained in the current <see cref="T:System.Runtime.Remoting.Messaging.ReturnMessage" />.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007DD RID: 2013
|
||||
// (get) Token: 0x06002820 RID: 10272 RVA: 0x00083618 File Offset: 0x00081818
|
||||
public virtual IDictionary Properties
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._properties == null)
|
||||
{
|
||||
this._properties = new MethodReturnDictionary(this);
|
||||
}
|
||||
return this._properties;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the name of the type on which the remote method was called.</summary>
|
||||
/// <returns>The type name of the remote object on which the remote method was called.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007DE RID: 2014
|
||||
// (get) Token: 0x06002821 RID: 10273 RVA: 0x00083638 File Offset: 0x00081838
|
||||
public string TypeName
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._methodBase != null && this._typeName == null)
|
||||
{
|
||||
this._typeName = this._methodBase.DeclaringType.AssemblyQualifiedName;
|
||||
}
|
||||
return this._typeName;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets or sets the URI of the remote object on which the remote method was called.</summary>
|
||||
/// <returns>The URI of the remote object on which the remote method was called.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007DF RID: 2015
|
||||
// (get) Token: 0x06002822 RID: 10274 RVA: 0x00083678 File Offset: 0x00081878
|
||||
// (set) Token: 0x06002823 RID: 10275 RVA: 0x00083680 File Offset: 0x00081880
|
||||
public string Uri
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._uri;
|
||||
}
|
||||
set
|
||||
{
|
||||
this._uri = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Returns a specified argument passed to the remote method during the method call.</summary>
|
||||
/// <returns>An argument passed to the remote method during the method call.</returns>
|
||||
/// <param name="argNum">The zero-based index of the requested argument. </param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002824 RID: 10276 RVA: 0x0008368C File Offset: 0x0008188C
|
||||
public object GetArg(int argNum)
|
||||
{
|
||||
return this._args[argNum];
|
||||
}
|
||||
|
||||
/// <summary>Returns the name of a specified method argument.</summary>
|
||||
/// <returns>The name of a specified method argument.</returns>
|
||||
/// <param name="index">The zero-based index of the requested argument name. </param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x06002825 RID: 10277 RVA: 0x00083698 File Offset: 0x00081898
|
||||
public string GetArgName(int index)
|
||||
{
|
||||
return this._methodBase.GetParameters()[index].Name;
|
||||
}
|
||||
|
||||
/// <summary>Gets the exception that was thrown during the remote method call.</summary>
|
||||
/// <returns>The exception thrown during the method call, or null if an exception did not occur during the call.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007E0 RID: 2016
|
||||
// (get) Token: 0x06002826 RID: 10278 RVA: 0x000836AC File Offset: 0x000818AC
|
||||
public Exception Exception
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._exception;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the number of out or ref arguments on the called method.</summary>
|
||||
/// <returns>The number of out or ref arguments on the called method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007E1 RID: 2017
|
||||
// (get) Token: 0x06002827 RID: 10279 RVA: 0x000836B4 File Offset: 0x000818B4
|
||||
public int OutArgCount
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._args == null || this._args.Length == 0)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
if (this._inArgInfo == null)
|
||||
{
|
||||
this._inArgInfo = new ArgInfo(this.MethodBase, ArgInfoType.Out);
|
||||
}
|
||||
return this._inArgInfo.GetInOutArgCount();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets a specified object passed as an out or ref parameter to the called method.</summary>
|
||||
/// <returns>An object passed as an out or ref parameter to the called method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007E2 RID: 2018
|
||||
// (get) Token: 0x06002828 RID: 10280 RVA: 0x00083704 File Offset: 0x00081904
|
||||
public object[] OutArgs
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this._outArgs == null && this._args != null)
|
||||
{
|
||||
if (this._inArgInfo == null)
|
||||
{
|
||||
this._inArgInfo = new ArgInfo(this.MethodBase, ArgInfoType.Out);
|
||||
}
|
||||
this._outArgs = this._inArgInfo.GetInOutArgs(this._args);
|
||||
}
|
||||
return this._outArgs;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Gets the object returned by the called method.</summary>
|
||||
/// <returns>The object returned by the called method.</returns>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x170007E3 RID: 2019
|
||||
// (get) Token: 0x06002829 RID: 10281 RVA: 0x00083764 File Offset: 0x00081964
|
||||
public virtual object ReturnValue
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._returnValue;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>Returns the object passed as an out or ref parameter during the remote method call.</summary>
|
||||
/// <returns>The object passed as an out or ref parameter during the remote method call.</returns>
|
||||
/// <param name="argNum">The zero-based index of the requested out or ref parameter. </param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x0600282A RID: 10282 RVA: 0x0008376C File Offset: 0x0008196C
|
||||
public object GetOutArg(int argNum)
|
||||
{
|
||||
if (this._inArgInfo == null)
|
||||
{
|
||||
this._inArgInfo = new ArgInfo(this.MethodBase, ArgInfoType.Out);
|
||||
}
|
||||
return this._args[this._inArgInfo.GetInOutArgIndex(argNum)];
|
||||
}
|
||||
|
||||
/// <summary>Returns the name of a specified out or ref parameter passed to the remote method.</summary>
|
||||
/// <returns>A string representing the name of the specified out or ref parameter, or null if the current method is not implemented.</returns>
|
||||
/// <param name="index">The zero-based index of the requested argument. </param>
|
||||
/// <PermissionSet>
|
||||
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="Infrastructure" />
|
||||
/// </PermissionSet>
|
||||
// Token: 0x0600282B RID: 10283 RVA: 0x000837AC File Offset: 0x000819AC
|
||||
public string GetOutArgName(int index)
|
||||
{
|
||||
if (this._inArgInfo == null)
|
||||
{
|
||||
this._inArgInfo = new ArgInfo(this.MethodBase, ArgInfoType.Out);
|
||||
}
|
||||
return this._inArgInfo.GetInOutArgName(index);
|
||||
}
|
||||
|
||||
// Token: 0x04000F93 RID: 3987
|
||||
private object[] _outArgs;
|
||||
|
||||
// Token: 0x04000F94 RID: 3988
|
||||
private object[] _args;
|
||||
|
||||
// Token: 0x04000F95 RID: 3989
|
||||
private int _outArgsCount;
|
||||
|
||||
// Token: 0x04000F96 RID: 3990
|
||||
private LogicalCallContext _callCtx;
|
||||
|
||||
// Token: 0x04000F97 RID: 3991
|
||||
private object _returnValue;
|
||||
|
||||
// Token: 0x04000F98 RID: 3992
|
||||
private string _uri;
|
||||
|
||||
// Token: 0x04000F99 RID: 3993
|
||||
private Exception _exception;
|
||||
|
||||
// Token: 0x04000F9A RID: 3994
|
||||
private MethodBase _methodBase;
|
||||
|
||||
// Token: 0x04000F9B RID: 3995
|
||||
private string _methodName;
|
||||
|
||||
// Token: 0x04000F9C RID: 3996
|
||||
private Type[] _methodSignature;
|
||||
|
||||
// Token: 0x04000F9D RID: 3997
|
||||
private string _typeName;
|
||||
|
||||
// Token: 0x04000F9E RID: 3998
|
||||
private MethodReturnDictionary _properties;
|
||||
|
||||
// Token: 0x04000F9F RID: 3999
|
||||
private Identity _targetIdentity;
|
||||
|
||||
// Token: 0x04000FA0 RID: 4000
|
||||
private ArgInfo _inArgInfo;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
using System;
|
||||
using System.Runtime.Remoting.Activation;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x02000405 RID: 1029
|
||||
internal class ServerContextTerminatorSink : IMessageSink
|
||||
{
|
||||
// Token: 0x0600282D RID: 10285 RVA: 0x000837E0 File Offset: 0x000819E0
|
||||
public IMessage SyncProcessMessage(IMessage msg)
|
||||
{
|
||||
if (msg is IConstructionCallMessage)
|
||||
{
|
||||
return ActivationServices.CreateInstanceFromMessage((IConstructionCallMessage)msg);
|
||||
}
|
||||
ServerIdentity serverIdentity = (ServerIdentity)RemotingServices.GetMessageTargetIdentity(msg);
|
||||
return serverIdentity.SyncObjectProcessMessage(msg);
|
||||
}
|
||||
|
||||
// Token: 0x0600282E RID: 10286 RVA: 0x00083818 File Offset: 0x00081A18
|
||||
public IMessageCtrl AsyncProcessMessage(IMessage msg, IMessageSink replySink)
|
||||
{
|
||||
ServerIdentity serverIdentity = (ServerIdentity)RemotingServices.GetMessageTargetIdentity(msg);
|
||||
return serverIdentity.AsyncObjectProcessMessage(msg, replySink);
|
||||
}
|
||||
|
||||
// Token: 0x170007E4 RID: 2020
|
||||
// (get) Token: 0x0600282F RID: 10287 RVA: 0x0008383C File Offset: 0x00081A3C
|
||||
public IMessageSink NextSink
|
||||
{
|
||||
get
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
using System;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x02000407 RID: 1031
|
||||
internal class ServerObjectReplySink : IMessageSink
|
||||
{
|
||||
// Token: 0x06002834 RID: 10292 RVA: 0x000838F0 File Offset: 0x00081AF0
|
||||
public ServerObjectReplySink(ServerIdentity identity, IMessageSink replySink)
|
||||
{
|
||||
this._replySink = replySink;
|
||||
this._identity = identity;
|
||||
}
|
||||
|
||||
// Token: 0x06002835 RID: 10293 RVA: 0x00083908 File Offset: 0x00081B08
|
||||
public IMessage SyncProcessMessage(IMessage msg)
|
||||
{
|
||||
this._identity.NotifyServerDynamicSinks(false, msg, true, true);
|
||||
return this._replySink.SyncProcessMessage(msg);
|
||||
}
|
||||
|
||||
// Token: 0x06002836 RID: 10294 RVA: 0x00083928 File Offset: 0x00081B28
|
||||
public IMessageCtrl AsyncProcessMessage(IMessage msg, IMessageSink replySink)
|
||||
{
|
||||
throw new NotSupportedException();
|
||||
}
|
||||
|
||||
// Token: 0x170007E6 RID: 2022
|
||||
// (get) Token: 0x06002837 RID: 10295 RVA: 0x00083930 File Offset: 0x00081B30
|
||||
public IMessageSink NextSink
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._replySink;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000FA2 RID: 4002
|
||||
private IMessageSink _replySink;
|
||||
|
||||
// Token: 0x04000FA3 RID: 4003
|
||||
private ServerIdentity _identity;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,57 @@
|
||||
using System;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x02000406 RID: 1030
|
||||
internal class ServerObjectTerminatorSink : IMessageSink
|
||||
{
|
||||
// Token: 0x06002830 RID: 10288 RVA: 0x00083840 File Offset: 0x00081A40
|
||||
public ServerObjectTerminatorSink(IMessageSink nextSink)
|
||||
{
|
||||
this._nextSink = nextSink;
|
||||
}
|
||||
|
||||
// Token: 0x06002831 RID: 10289 RVA: 0x00083850 File Offset: 0x00081A50
|
||||
public IMessage SyncProcessMessage(IMessage msg)
|
||||
{
|
||||
ServerIdentity serverIdentity = (ServerIdentity)RemotingServices.GetMessageTargetIdentity(msg);
|
||||
serverIdentity.NotifyServerDynamicSinks(true, msg, false, false);
|
||||
IMessage message = this._nextSink.SyncProcessMessage(msg);
|
||||
serverIdentity.NotifyServerDynamicSinks(false, msg, false, false);
|
||||
return message;
|
||||
}
|
||||
|
||||
// Token: 0x06002832 RID: 10290 RVA: 0x0008388C File Offset: 0x00081A8C
|
||||
public IMessageCtrl AsyncProcessMessage(IMessage msg, IMessageSink replySink)
|
||||
{
|
||||
ServerIdentity serverIdentity = (ServerIdentity)RemotingServices.GetMessageTargetIdentity(msg);
|
||||
if (serverIdentity.HasServerDynamicSinks)
|
||||
{
|
||||
serverIdentity.NotifyServerDynamicSinks(true, msg, false, true);
|
||||
if (replySink != null)
|
||||
{
|
||||
replySink = new ServerObjectReplySink(serverIdentity, replySink);
|
||||
}
|
||||
}
|
||||
IMessageCtrl messageCtrl = this._nextSink.AsyncProcessMessage(msg, replySink);
|
||||
if (replySink == null)
|
||||
{
|
||||
serverIdentity.NotifyServerDynamicSinks(false, msg, true, true);
|
||||
}
|
||||
return messageCtrl;
|
||||
}
|
||||
|
||||
// Token: 0x170007E5 RID: 2021
|
||||
// (get) Token: 0x06002833 RID: 10291 RVA: 0x000838E8 File Offset: 0x00081AE8
|
||||
public IMessageSink NextSink
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._nextSink;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000FA1 RID: 4001
|
||||
private IMessageSink _nextSink;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,105 @@
|
||||
using System;
|
||||
using System.Reflection;
|
||||
using System.Runtime.Remoting.Proxies;
|
||||
using System.Threading;
|
||||
|
||||
namespace System.Runtime.Remoting.Messaging
|
||||
{
|
||||
// Token: 0x02000408 RID: 1032
|
||||
internal class StackBuilderSink : IMessageSink
|
||||
{
|
||||
// Token: 0x06002838 RID: 10296 RVA: 0x00083938 File Offset: 0x00081B38
|
||||
public StackBuilderSink(MarshalByRefObject obj, bool forceInternalExecute)
|
||||
{
|
||||
this._target = obj;
|
||||
if (!forceInternalExecute && RemotingServices.IsTransparentProxy(obj))
|
||||
{
|
||||
this._rp = RemotingServices.GetRealProxy(obj);
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06002839 RID: 10297 RVA: 0x00083970 File Offset: 0x00081B70
|
||||
public IMessage SyncProcessMessage(IMessage msg)
|
||||
{
|
||||
this.CheckParameters(msg);
|
||||
if (this._rp != null)
|
||||
{
|
||||
return this._rp.Invoke(msg);
|
||||
}
|
||||
return RemotingServices.InternalExecuteMessage(this._target, (IMethodCallMessage)msg);
|
||||
}
|
||||
|
||||
// Token: 0x0600283A RID: 10298 RVA: 0x000839B0 File Offset: 0x00081BB0
|
||||
public IMessageCtrl AsyncProcessMessage(IMessage msg, IMessageSink replySink)
|
||||
{
|
||||
object[] array = new object[] { msg, replySink };
|
||||
ThreadPool.QueueUserWorkItem(new WaitCallback(this.ExecuteAsyncMessage), array);
|
||||
return null;
|
||||
}
|
||||
|
||||
// Token: 0x0600283B RID: 10299 RVA: 0x000839E0 File Offset: 0x00081BE0
|
||||
private void ExecuteAsyncMessage(object ob)
|
||||
{
|
||||
object[] array = (object[])ob;
|
||||
IMethodCallMessage methodCallMessage = (IMethodCallMessage)array[0];
|
||||
IMessageSink messageSink = (IMessageSink)array[1];
|
||||
this.CheckParameters(methodCallMessage);
|
||||
IMessage message;
|
||||
if (this._rp != null)
|
||||
{
|
||||
message = this._rp.Invoke(methodCallMessage);
|
||||
}
|
||||
else
|
||||
{
|
||||
message = RemotingServices.InternalExecuteMessage(this._target, methodCallMessage);
|
||||
}
|
||||
messageSink.SyncProcessMessage(message);
|
||||
}
|
||||
|
||||
// Token: 0x170007E7 RID: 2023
|
||||
// (get) Token: 0x0600283C RID: 10300 RVA: 0x00083A40 File Offset: 0x00081C40
|
||||
public IMessageSink NextSink
|
||||
{
|
||||
get
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x0600283D RID: 10301 RVA: 0x00083A44 File Offset: 0x00081C44
|
||||
private void CheckParameters(IMessage msg)
|
||||
{
|
||||
IMethodCallMessage methodCallMessage = (IMethodCallMessage)msg;
|
||||
ParameterInfo[] parameters = methodCallMessage.MethodBase.GetParameters();
|
||||
int num = 0;
|
||||
foreach (ParameterInfo parameterInfo in parameters)
|
||||
{
|
||||
object arg = methodCallMessage.GetArg(num++);
|
||||
Type type = parameterInfo.ParameterType;
|
||||
if (type.IsByRef)
|
||||
{
|
||||
type = type.GetElementType();
|
||||
}
|
||||
if (arg != null && !type.IsInstanceOfType(arg))
|
||||
{
|
||||
throw new RemotingException(string.Concat(new object[]
|
||||
{
|
||||
"Cannot cast argument ",
|
||||
parameterInfo.Position,
|
||||
" of type '",
|
||||
arg.GetType().AssemblyQualifiedName,
|
||||
"' to type '",
|
||||
type.AssemblyQualifiedName,
|
||||
"'"
|
||||
}));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x04000FA4 RID: 4004
|
||||
private MarshalByRefObject _target;
|
||||
|
||||
// Token: 0x04000FA5 RID: 4005
|
||||
private RealProxy _rp;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user