2002-07-31 Duncan Mak <duncan@ximian.com>
authorDuncan Mak <duncan@mono-cvs.ximian.com>
Tue, 30 Jul 2002 19:05:13 +0000 (19:05 -0000)
committerDuncan Mak <duncan@mono-cvs.ximian.com>
Tue, 30 Jul 2002 19:05:13 +0000 (19:05 -0000)
* unix.args: Added new Exceptions, Interfaces and various
TypeEntries from System.Runtime.Remoting.

* TypeEntry.cs:
* ActivatedClientTypeEntry.cs:
* ActivatedServiceTypeEntry.cs:
* WellKnownClientTypeEntry.cs:
* WellKnownServiceTypeEntry.cs: Added all the classes derived from TypeEntry.

* RemotingException.cs:
* RemotingTimeoutException.cs:
* ServerException.cs: Added missing exceptions.

* IChannelInfo.cs:
* IEnvoyInfo.cs:
* IRemotingTypeInfo.cs: Added missing interfaces.

svn path=/trunk/mcs/; revision=6263

14 files changed:
mcs/class/corlib/ChangeLog
mcs/class/corlib/System.Runtime.Remoting/ActivatedClientTypeEntry.cs [new file with mode: 0644]
mcs/class/corlib/System.Runtime.Remoting/ActivatedServiceTypeEntry.cs [new file with mode: 0644]
mcs/class/corlib/System.Runtime.Remoting/ChangeLog
mcs/class/corlib/System.Runtime.Remoting/IChannelInfo.cs [new file with mode: 0644]
mcs/class/corlib/System.Runtime.Remoting/IEnvoyInfo.cs [new file with mode: 0644]
mcs/class/corlib/System.Runtime.Remoting/IRemotingTypeInfo.cs [new file with mode: 0644]
mcs/class/corlib/System.Runtime.Remoting/RemotingException.cs [new file with mode: 0644]
mcs/class/corlib/System.Runtime.Remoting/RemotingTimeoutException.cs [new file with mode: 0644]
mcs/class/corlib/System.Runtime.Remoting/ServerException.cs [new file with mode: 0644]
mcs/class/corlib/System.Runtime.Remoting/TypeEntry.cs [new file with mode: 0644]
mcs/class/corlib/System.Runtime.Remoting/WellKnownClientTypeEntry.cs [new file with mode: 0644]
mcs/class/corlib/System.Runtime.Remoting/WellKnownServiceTypeEntry.cs [new file with mode: 0644]
mcs/class/corlib/unix.args

index 345cd72875c7e9af01712a367b2905cc7cea9743..a942b83a19476861e9874de6927c8776281a5a57 100644 (file)
@@ -1,3 +1,8 @@
+2002-07-31  Duncan Mak  <duncan@ximian.com>
+
+       * unix.args: Added new Exceptions, Interfaces and various
+       TypeEntries from System.Runtime.Remoting.
+
 2002-07-29  Martin Baulig  <martin@gnome.org>
 
        * list: Removed, this isn't used anymore and people are already
diff --git a/mcs/class/corlib/System.Runtime.Remoting/ActivatedClientTypeEntry.cs b/mcs/class/corlib/System.Runtime.Remoting/ActivatedClientTypeEntry.cs
new file mode 100644 (file)
index 0000000..eb0deca
--- /dev/null
@@ -0,0 +1,41 @@
+//
+// System.Runtime.Remoting.ActivatedClientTypeEntry.cs
+//
+// AUthor: Duncan Mak  (duncan@ximian.com)
+//
+// 2002 (C) Copyright. Ximian, Inc.
+//
+
+using System;
+using System.Runtime.Remoting;
+using System.Runtime.Remoting.Contexts;
+
+namespace System.Runtime.Remoting {
+
+       public class ActivatedClientTypeEntry : TypeEntry
+       {
+               string url;
+               Type obj_type;
+               
+               public ActivatedClientTypeEntry (Type type, string appUrl)
+               {
+                       AssemblyName = type.Assembly.FullName;
+                       TypeName = type.FullName;
+                       url = appUrl;
+                       obj_type = type;
+               }
+
+               public string ApplicationUrl {
+                       get { return url; }
+               }
+
+               public IContextAttribute [] ContextAttributes {
+                       get { return null; }
+                       set { } // This is not implemented in the MS runtime yet.
+               }
+
+               public Type ObjectType {
+                       get { return obj_type; }
+               }
+       }
+}
diff --git a/mcs/class/corlib/System.Runtime.Remoting/ActivatedServiceTypeEntry.cs b/mcs/class/corlib/System.Runtime.Remoting/ActivatedServiceTypeEntry.cs
new file mode 100644 (file)
index 0000000..e0736ec
--- /dev/null
@@ -0,0 +1,44 @@
+//
+// System.Runtime.Remoting.ActivatedServiceTypeEntry.cs
+//
+// AUthor: Duncan Mak  (duncan@ximian.com)
+//
+// 2002 (C) Copyright. Ximian, Inc.
+//
+
+using System;
+using System.Reflection;
+using System.Runtime.Remoting;
+using System.Runtime.Remoting.Contexts;
+
+namespace System.Runtime.Remoting {
+
+       public class ActivatedServiceTypeEntry : TypeEntry
+       {
+               Type obj_type;
+               
+               public ActivatedServiceTypeEntry (Type type)                    
+               {
+                       AssemblyName = type.Assembly.FullName;
+                       TypeName = type.FullName;
+                       obj_type = type;
+               }
+
+               public ActivatedServiceTypeEntry (string typeName, string assemblyName)
+               {
+                       AssemblyName = assemblyName;
+                       TypeName = typeName;
+                       Assembly a = Assembly.Load (assemblyName);
+                       obj_type = a.GetType (typeName);
+               }
+               
+               public IContextAttribute [] ContextAttributes {
+                       get { return null; }
+                       set { } // This is not implemented in the MS runtime yet.
+               }
+
+               public Type ObjectType {
+                       get { return obj_type; }
+               }
+       }
+}
index b33d476a84a3989bfc635833e7abf0821f2ad21b..c9e792101f272c295e53f601d7d4077d206bef27 100755 (executable)
@@ -1,3 +1,19 @@
+2002-07-31  Duncan Mak  <duncan@ximian.com>
+
+       * TypeEntry.cs:
+       * ActivatedClientTypeEntry.cs:
+       * ActivatedServiceTypeEntry.cs:
+       * WellKnownClientTypeEntry.cs:
+       * WellKnownServiceTypeEntry.cs: Added all the classes derived from TypeEntry.
+
+       * RemotingException.cs: 
+       * RemotingTimeoutException.cs: 
+       * ServerException.cs: Added missing exceptions.
+
+       * IChannelInfo.cs: 
+       * IEnvoyInfo.cs: 
+       * IRemotingTypeInfo.cs: Added missing interfaces.
+
 2002-07-24  Duncan Mak  <duncan@ximian.com>
 
        * LeaseState.cs: Moved to System.Runtime.Remoting.Lifetime.
diff --git a/mcs/class/corlib/System.Runtime.Remoting/IChannelInfo.cs b/mcs/class/corlib/System.Runtime.Remoting/IChannelInfo.cs
new file mode 100644 (file)
index 0000000..643d569
--- /dev/null
@@ -0,0 +1,17 @@
+//
+// System.Runtime.Remoting.IChannelInfo.cs
+//
+// AUthor: Duncan Mak  (duncan@ximian.com)
+//
+// 2002 (C) Copyright. Ximian, Inc.
+//
+
+using System;
+
+namespace System.Runtime.Remoting {
+
+       public interface IChannelInfo
+       {
+               object[] ChannelData { get; set; }
+       }
+}
diff --git a/mcs/class/corlib/System.Runtime.Remoting/IEnvoyInfo.cs b/mcs/class/corlib/System.Runtime.Remoting/IEnvoyInfo.cs
new file mode 100644 (file)
index 0000000..d66709a
--- /dev/null
@@ -0,0 +1,17 @@
+//
+// System.Runtime.Remoting.IEnvoyInfo.cs
+//
+// AUthor: Duncan Mak  (duncan@ximian.com)
+//
+// 2002 (C) Copyright. Ximian, Inc.
+//
+
+using System.Runtime.Remoting.Messaging;
+
+namespace System.Runtime.Remoting {
+
+       public interface IEnvoyInfo
+       {
+               IMessageSink EnvoySinks { get; set; }
+       }
+}
diff --git a/mcs/class/corlib/System.Runtime.Remoting/IRemotingTypeInfo.cs b/mcs/class/corlib/System.Runtime.Remoting/IRemotingTypeInfo.cs
new file mode 100644 (file)
index 0000000..eb4e9d3
--- /dev/null
@@ -0,0 +1,18 @@
+//
+// System.Runtime.Remoting.IRemotingTypeInfo.cs
+//
+// AUthor: Duncan Mak  (duncan@ximian.com)
+//
+// 2002 (C) Copyright. Ximian, Inc.
+//
+
+using System.Runtime.Remoting.Messaging;
+
+namespace System.Runtime.Remoting {
+
+       public interface IRemotingTypeInfo
+       {
+               string TypeName { get; set; }
+               bool CanCastTo (Type fromType, object o);
+       }
+}
diff --git a/mcs/class/corlib/System.Runtime.Remoting/RemotingException.cs b/mcs/class/corlib/System.Runtime.Remoting/RemotingException.cs
new file mode 100644 (file)
index 0000000..eb23b42
--- /dev/null
@@ -0,0 +1,37 @@
+//
+// System.Runtime.Remoting.RemotingException.cs
+//
+// AUthor: Duncan Mak  (duncan@ximian.com)
+//
+// 2002 (C) Copyright. Ximian, Inc.
+//
+
+using System;
+using System.Runtime.Serialization;
+
+namespace System.Runtime.Remoting {
+
+       [Serializable]
+       public class RemotingException : Exception
+       {
+               public RemotingException ()
+                       : base ()
+               {
+               }
+
+               public RemotingException (string message)
+                       : base (message)
+               {
+               }
+
+               protected RemotingException (SerializationInfo info, StreamingContext context)
+                       : base (info, context)
+               {
+               }
+
+               public RemotingException (string message, Exception ex)
+                       : base (message, ex)
+               {
+               }
+       }
+}
diff --git a/mcs/class/corlib/System.Runtime.Remoting/RemotingTimeoutException.cs b/mcs/class/corlib/System.Runtime.Remoting/RemotingTimeoutException.cs
new file mode 100644 (file)
index 0000000..af2f446
--- /dev/null
@@ -0,0 +1,32 @@
+//
+// System.Runtime.Remoting.RemotingTimeoutException.cs
+//
+// AUthor: Duncan Mak  (duncan@ximian.com)
+//
+// 2002 (C) Copyright. Ximian, Inc.
+//
+
+using System;
+using System.Runtime.Serialization;
+
+namespace System.Runtime.Remoting {
+
+       [Serializable]
+       public class RemotingTimeoutException : RemotingException
+       {
+               public RemotingTimeoutException ()
+                       : base ()
+               {
+               }
+
+               public RemotingTimeoutException (string message)
+                       : base (message)
+               {
+               }
+
+               public RemotingTimeoutException (string message, Exception ex)
+                       : base (message, ex)
+               {
+               }
+       }
+}
diff --git a/mcs/class/corlib/System.Runtime.Remoting/ServerException.cs b/mcs/class/corlib/System.Runtime.Remoting/ServerException.cs
new file mode 100644 (file)
index 0000000..becfb5d
--- /dev/null
@@ -0,0 +1,32 @@
+//
+// System.Runtime.Remoting.ServerException.cs
+//
+// AUthor: Duncan Mak  (duncan@ximian.com)
+//
+// 2002 (C) Copyright. Ximian, Inc.
+//
+
+using System;
+using System.Runtime.Serialization;
+
+namespace System.Runtime.Remoting {
+
+       [Serializable]
+       public class ServerException : SystemException
+       {
+               public ServerException ()
+                       : base ()
+               {
+               }
+
+               public ServerException (string message)
+                       : base (message)
+               {
+               }
+
+               public ServerException (string message, Exception ex)
+                       : base (message, ex)
+               {
+               }
+       }
+}
diff --git a/mcs/class/corlib/System.Runtime.Remoting/TypeEntry.cs b/mcs/class/corlib/System.Runtime.Remoting/TypeEntry.cs
new file mode 100644 (file)
index 0000000..a39e848
--- /dev/null
@@ -0,0 +1,32 @@
+//
+// System.Runtime.Remoting.TypeEntry.cs
+//
+// AUthor: Duncan Mak  (duncan@ximian.com)
+//
+// 2002 (C) Copyright. Ximian, Inc.
+//
+
+using System;
+
+namespace System.Runtime.Remoting {
+
+       public class TypeEntry
+       {
+               string assembly_name;
+               string type_name;
+               
+               protected TypeEntry ()
+               {
+               }
+
+               public string AssemblyName {
+                       get { return assembly_name; }
+                       set { assembly_name = value; }
+               }
+
+               public string TypeName {
+                       get { return type_name; }
+                       set { type_name = value; }
+               }
+       }
+}
diff --git a/mcs/class/corlib/System.Runtime.Remoting/WellKnownClientTypeEntry.cs b/mcs/class/corlib/System.Runtime.Remoting/WellKnownClientTypeEntry.cs
new file mode 100644 (file)
index 0000000..84ec479
--- /dev/null
@@ -0,0 +1,58 @@
+//
+// System.Runtime.Remoting.WellKnownClientTypeEntry.cs
+//
+// AUthor: Duncan Mak  (duncan@ximian.com)
+//
+// 2002 (C) Copyright. Ximian, Inc.
+//
+
+using System;
+using System.Reflection;
+
+namespace System.Runtime.Remoting {
+
+       public class WellKnownClientTypeEntry : TypeEntry
+       {
+               Type obj_type;
+               string obj_url;
+               string app_url = null;
+               
+               public WellKnownClientTypeEntry (Type type, string objectUrl )
+               {
+                       AssemblyName = type.Assembly.FullName;
+                       TypeName = type.FullName;
+                       obj_type = type;
+                       obj_url = objectUrl;
+               }
+
+               public WellKnownClientTypeEntry (string typeName, string assemblyName, string objectUrl)
+               {
+                       AssemblyName = assemblyName;
+                       TypeName = typeName;
+                       Assembly a = Assembly.Load (assemblyName);
+                       obj_type = a.GetType (typeName);
+               }
+
+               public string ApplicationUrl {
+                       get { return app_url; }
+                       set { app_url = value; }
+               }
+
+               public Type ObjectType {
+                       get { return obj_type; }
+               }
+
+               public string ObjectUrl {
+                       get { return obj_url; }
+                       set { obj_url = value; }
+               }
+
+               public override string ToString ()
+               {
+                       if (ApplicationUrl != null)
+                               return TypeName + AssemblyName + ObjectUrl + ApplicationUrl;
+                       else
+                               return TypeName + AssemblyName + ObjectUrl;
+               }
+       }
+}
diff --git a/mcs/class/corlib/System.Runtime.Remoting/WellKnownServiceTypeEntry.cs b/mcs/class/corlib/System.Runtime.Remoting/WellKnownServiceTypeEntry.cs
new file mode 100644 (file)
index 0000000..85a2683
--- /dev/null
@@ -0,0 +1,66 @@
+//
+// System.Runtime.Remoting.WellKnownServiceTypeEntry.cs
+//
+// AUthor: Duncan Mak  (duncan@ximian.com)
+//
+// 2002 (C) Copyright. Ximian, Inc.
+//
+
+using System;
+using System.Reflection;
+using System.Runtime.Remoting.Contexts;
+
+namespace System.Runtime.Remoting {
+
+       public class WellKnownServiceTypeEntry : TypeEntry
+       {
+               Type obj_type;
+               string obj_uri;
+               WellKnownObjectMode obj_mode;
+               
+               public WellKnownServiceTypeEntry (Type type, string objectUri, WellKnownObjectMode mode)                        
+               {
+                       AssemblyName = type.Assembly.FullName;
+                       TypeName = type.FullName;
+                       obj_type = type;
+                       obj_uri = objectUri;
+                       obj_mode = mode;
+               }
+
+               public WellKnownServiceTypeEntry (string typeName, string assemblyName,
+                                                 string objectUri, WellKnownObjectMode mode)                   
+               {
+                       AssemblyName = assemblyName;
+                       TypeName = typeName;
+                       Assembly a = Assembly.Load (assemblyName);
+                       obj_type = a.GetType (typeName);
+                       obj_uri = objectUri;
+                       obj_mode = mode;
+               }
+
+               public IContextAttribute [] ContextAttributes {
+                       get { return null; }
+                       set { } // This is not implemented in the MS runtime yet.
+               }
+
+               public WellKnownObjectMode Mode {
+                       get { return obj_mode; }
+                       set { obj_mode = value; }
+               }
+
+               public Type ObjectType {
+                       get { return obj_type; }
+               }
+
+               public string ObjectUri {
+                       get { return obj_uri; }
+                       set { obj_uri = value; }
+               }
+
+               [MonoTODO]
+               public override string ToString ()
+               {
+                       return TypeName + AssemblyName + ObjectUri;
+               }
+       }
+}
index e15ee436e1c474fabb8e188706b1609466440bc3..dd9e7314f10ea0af7ef784fec9b212ac032e96eb 100755 (executable)
@@ -436,11 +436,22 @@ System.Runtime.InteropServices/UCOMTypeInfo.cs
 System.Runtime.InteropServices/UCOMTypeLib.cs
 System.Runtime.InteropServices/UnmanagedType.cs
 System.Runtime.InteropServices/VarEnum.cs
+System.Runtime.Remoting/ActivatedClientTypeEntry.cs
+System.Runtime.Remoting/ActivatedServiceTypeEntry.cs
 System.Runtime.Remoting/IObjectHandle.cs
+System.Runtime.Remoting/IChannelInfo.cs
+System.Runtime.Remoting/IEnvoyInfo.cs
+System.Runtime.Remoting/IRemotingTypeInfo.cs
 System.Runtime.Remoting/ObjectHandle.cs
 System.Runtime.Remoting/ObjRef.cs
+System.Runtime.Remoting/RemotingException.cs
+System.Runtime.Remoting/RemotingTimeoutException.cs
 System.Runtime.Remoting/RemotingServices.cs
+System.Runtime.Remoting/ServerException.cs
+System.Runtime.Remoting/TypeEntry.cs
 System.Runtime.Remoting/WellKnownObjectMode.cs
+System.Runtime.Remoting/WellKnownClientTypeEntry.cs
+System.Runtime.Remoting/WellKnownServiceTypeEntry.cs
 System.Runtime.Remoting.Activation/ActivatorLevel.cs
 System.Runtime.Remoting.Activation/IActivator.cs
 System.Runtime.Remoting.Activation/IConstructionCallMessage.cs