[Mono-bugs] [Bug 79639][Wis] New - System.ComponentModel.ComplexBindingPropertiesAttribute suggested implementation

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Tue Oct 10 20:32:12 EDT 2006


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by malafaya at clix.pt.

http://bugzilla.ximian.com/show_bug.cgi?id=79639

--- shadow/79639	2006-10-10 20:32:12.000000000 -0400
+++ shadow/79639.tmp.19035	2006-10-10 20:32:12.000000000 -0400
@@ -0,0 +1,130 @@
+Bug#: 79639
+Product: Mono: Class Libraries
+Version: 1.1
+OS: All
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Wishlist
+Component: System
+AssignedTo: mono-bugs at ximian.com                            
+ReportedBy: malafaya at clix.pt               
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: System.ComponentModel.ComplexBindingPropertiesAttribute suggested implementation
+
+Please fill in this template when reporting a bug, unless you know what 
+you are doing.
+Description of Problem:
+Suggested implementation of missing .NET 2.0 class 
+System.ComponentModel.ComplexBindingPropertiesAttribute
+
+Steps to reproduce the problem:
+1. Just try to instantiate an object of that class (it's missing)
+2. 
+3. 
+
+Actual Results:
+
+
+Expected Results:
+
+
+How often does this happen? 
+
+
+Additional Information:
+
+================================
+
+Implementation: (P.S. it hasn't been compiled nor tested! take a look 
+before comitting)
+------------------------
+
+
+
+//
+// System.ComponentModel.ComplexBindingPropertiesAttribute
+//
+// Authors:
+//  André Malafaya Baptista (malafaya at clix.pt)
+//
+// (C) 2006 André Malafaya Baptista
+//
+
+//
+// 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.
+//
+
+namespace System.ComponentModel
+{
+#if NET_2_0
+	[AttributeUsageAttribute(AttributeTargets.Class)] 
+	public sealed class ComplexBindingPropertiesAttribute : Attribute
+	{
+		private string _dataSource;
+		private string _dataMember;
+	
+		public static readonly ComplexBindingPropertiesAttribute 
+Default = null;
+
+		public ComplexBindingPropertiesAttribute ()
+		{
+		}
+
+		public ComplexBindingPropertiesAttribute (string 
+dataSource)
+		{
+			_dataSource = dataSource;
+		}
+
+		public ComplexBindingPropertiesAttribute (string 
+dataSource, string dataMember)
+		{
+			_dataSource = dataSource;
+			_dataMember = dataMember;
+		}
+
+		public string DataMember
+		{
+			get { return _dataMember; }
+		}
+		
+		public string DataSource
+		{
+			get { return _dataSource; }
+		}
+		
+		public override bool Equals (object obj)
+		{
+			if (!(obj is ComplexBindingPropertiesAttribute))
+				return false;
+				
+			return (_dataSource == 
+((ComplexBindingPropertiesAttribute)objB).DataSource && 
+				_dataMember == 
+((ComplexBindingPropertiesAttribute)objB).DataMember);
+		}
+	}
+#endif
+}


More information about the mono-bugs mailing list