ChangeLog: Updated ChangeLog.
authorSanja Gupta <sanjay@mono-cvs.ximian.com>
Wed, 29 Sep 2004 11:16:12 +0000 (11:16 -0000)
committerSanja Gupta <sanjay@mono-cvs.ximian.com>
Wed, 29 Sep 2004 11:16:12 +0000 (11:16 -0000)
ConnectionPoint.cs: Initial implementation.
ConsumerConnectionPoint.cs:
ProviderConnectionPoint.cs: Added stubs.
TypeCollection.cs: Completed.

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

mcs/class/System.Web/System.Web.UI.WebControls.WebParts/ChangeLog
mcs/class/System.Web/System.Web.UI.WebControls.WebParts/ConnectionPoint.cs [new file with mode: 0644]
mcs/class/System.Web/System.Web.UI.WebControls.WebParts/ConsumerConnectionPoint.cs [new file with mode: 0644]
mcs/class/System.Web/System.Web.UI.WebControls.WebParts/ProviderConnectionPoint.cs [new file with mode: 0644]
mcs/class/System.Web/System.Web.UI.WebControls.WebParts/TypeCollection.cs [new file with mode: 0644]

index be8d7df48d532fb18fa7e28830828c41aed79b77..ce3c93b1db4453a10cc2a8b558e8f441b96faeb5 100644 (file)
@@ -1,3 +1,10 @@
+2004-09-29  Sanjay Gupta <gsanjay@novell.com>
+
+       * ConnectionPoint.cs: Initial implementation.
+       * ConsumerConnectionPoint.cs:
+       * ProviderConnectionPoint.cs: Added stubs.
+       * TypeCollection.cs: Completed.
+
 2004-09-29  Sanjay Gupta <gsanjay@novell.com>
                
        * IWebPart.cs: Added new property and removed extra property.
diff --git a/mcs/class/System.Web/System.Web.UI.WebControls.WebParts/ConnectionPoint.cs b/mcs/class/System.Web/System.Web.UI.WebControls.WebParts/ConnectionPoint.cs
new file mode 100644 (file)
index 0000000..bc3ffce
--- /dev/null
@@ -0,0 +1,84 @@
+//
+// System.Web.UI.WebControls.WebParts.ConnectionPoint.cs
+//
+// Author: Sanjay Gupta (gsanjay@novell.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+// Copyright (C) 2004 Novell, Inc (http://www.novell.com)
+//
+
+#if NET_2_0
+using System.Web;
+using System.Reflection;
+
+namespace System.Web.UI.WebControls.WebParts {
+        public abstract class ConnectionPoint 
+       {
+               private bool allowMultiConn;
+               private string name = string.Empty;
+               private string id = "default";
+               private Type interfaceType;
+               private Type controlType;
+               private Control control;
+               private MethodInfo callBackMethod;
+               
+               public const string DefaultID = "default";
+
+               internal ConnectionPoint (MethodInfo callBack, Type interFace, 
+                                       Type control, string name, string id, 
+                                                       bool allowsMultiConnections)
+               {
+                       this.allowMultiConn = allowsMultiConnections;
+                       this.interfaceType = interFace;
+                       this.controlType = control;
+                       this.name = name;
+                       this.id = id;
+                       this.callBackMethod = callBack;
+               }
+               
+               [MonoTODO]
+               public virtual bool GetEnabled (Control control)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               public bool AllowsMultipleConnections {
+                       get { return allowMultiConn; }
+               }
+
+               public Type ControlType {
+                       get { return controlType; }
+               }
+
+               public string ID {
+                       get { return id; }
+               }
+
+               public Type InterfaceType { 
+                       get { return interfaceType; }
+               }
+
+               public string Name { 
+                       get { return name;}
+               }       
+        }
+}
+#endif
\ No newline at end of file
diff --git a/mcs/class/System.Web/System.Web.UI.WebControls.WebParts/ConsumerConnectionPoint.cs b/mcs/class/System.Web/System.Web.UI.WebControls.WebParts/ConsumerConnectionPoint.cs
new file mode 100644 (file)
index 0000000..85d32ff
--- /dev/null
@@ -0,0 +1,57 @@
+//
+// System.Web.UI.WebControls.WebParts.ConsumerConnectionPoint.cs
+//
+// Author: Sanjay Gupta (gsanjay@novell.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+// Copyright (C) 2004 Novell, Inc (http://www.novell.com)
+//
+
+#if NET_2_0
+using System.Web;
+using System.Reflection;
+
+namespace System.Web.UI.WebControls.WebParts
+{
+       public class ConsumerConnectionPoint : ConnectionPoint
+       {
+               public ConsumerConnectionPoint (MethodInfo callBack, Type interFace,
+                       Type control, string name, string id, 
+                       bool allowsMultiConnections) : base (callBack, interFace,
+                                       control, name, id, allowsMultiConnections)
+               {                       
+               }
+
+               [MonoTODO]
+               public virtual void SetObject (Control control, object data)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [MonoTODO]
+               public virtual bool SupportsConnection (Control control, 
+                                                       TypeCollection interfaces)
+               {
+                       throw new NotImplementedException ();
+               }                       
+       }
+}
+#endif
\ No newline at end of file
diff --git a/mcs/class/System.Web/System.Web.UI.WebControls.WebParts/ProviderConnectionPoint.cs b/mcs/class/System.Web/System.Web.UI.WebControls.WebParts/ProviderConnectionPoint.cs
new file mode 100644 (file)
index 0000000..d3e8ce3
--- /dev/null
@@ -0,0 +1,56 @@
+//
+// System.Web.UI.WebControls.WebParts.ProviderConnectionPoint.cs
+//
+// Author: Sanjay Gupta (gsanjay@novell.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+// Copyright (C) 2004 Novell, Inc (http://www.novell.com)
+//
+
+#if NET_2_0
+using System.Web;
+using System.Reflection;
+
+namespace System.Web.UI.WebControls.WebParts
+{
+       public class ProviderConnectionPoint : ConnectionPoint
+       {
+               public ProviderConnectionPoint (MethodInfo callBack, Type interFace,
+                       Type control, string name, string id,
+                       bool allowsMultiConnections) : base (callBack, interFace,
+                                       control, name, id, allowsMultiConnections)
+               {
+               }
+
+               [MonoTODO]
+               public virtual void GetObject (Control control)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [MonoTODO]
+               public virtual TypeCollection GetSecondaryInterfaces (Control control)
+               {
+                       throw new NotImplementedException ();
+               }
+       }
+}
+#endif
\ No newline at end of file
diff --git a/mcs/class/System.Web/System.Web.UI.WebControls.WebParts/TypeCollection.cs b/mcs/class/System.Web/System.Web.UI.WebControls.WebParts/TypeCollection.cs
new file mode 100644 (file)
index 0000000..573ab82
--- /dev/null
@@ -0,0 +1,77 @@
+//
+// System.Web.UI.WebControls.WebParts.TypeCollection.cs
+//
+// Authors:
+//      Sanjay Gupta (gsanjay@novell.com)
+//
+// (C) 2004 Novell, Inc (http://www.novell.com)
+//
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+#if NET_2_0
+
+using System.Collections;
+using System.Reflection;
+
+namespace System.Web.UI.WebControls.WebParts
+{
+       public class TypeCollection : ReadOnlyCollectionBase
+       {
+               public TypeCollection ()
+               {                       
+               }
+
+               public TypeCollection (ICollection types)
+               {
+                       InnerList.AddRange (types);
+               }
+
+               public TypeCollection (TypeCollection existingTypes, 
+                                                               ICollection types)
+               {
+                       InnerList.AddRange (existingTypes.InnerList);
+                       InnerList.AddRange (types);
+               }
+
+               public static readonly TypeCollection Empty = new TypeCollection ();
+
+               public bool Contains (Type value)
+               {
+                       return InnerList.Contains (value);
+               }
+
+               public void CopyTo (Type [] array, int index)
+               {
+                       InnerList.CopyTo (0, array, index, Count);              
+               }
+
+               public int IndexOf (Type value)
+               {
+                       return (InnerList.IndexOf (value));
+               }
+
+               public Type this [int index ] {
+                       get { return (Type)InnerList [index]; }
+               }
+       }
+}
+#endif