* OdbcParameter.cs: added missing attributes
authorUmadevi S <uma@mono-cvs.ximian.com>
Wed, 2 Jun 2004 05:02:58 +0000 (05:02 -0000)
committerUmadevi S <uma@mono-cvs.ximian.com>
Wed, 2 Jun 2004 05:02:58 +0000 (05:02 -0000)
       * OdbcPermission.cs: added missing attributes
       * OdbcConnection.cs: fixes attribute, added missing attributes
       * OdbcInfoMessageEventArgs.cs: removed extra properties, fixed
       API compatibility with MS.NET
       * OdbcCommandBuilder.cs: use correct attributes

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

mcs/class/System.Data/System.Data.Odbc/ChangeLog
mcs/class/System.Data/System.Data.Odbc/OdbcCommandBuilder.cs
mcs/class/System.Data/System.Data.Odbc/OdbcConnection.cs
mcs/class/System.Data/System.Data.Odbc/OdbcInfoMessageEventArgs.cs
mcs/class/System.Data/System.Data.Odbc/OdbcParameter.cs
mcs/class/System.Data/System.Data.Odbc/OdbcPermission.cs

index b91a8b9c2a80f679e7873fce421425cee1435dbf..ab6f1524e6073ec56b633c474e294fc54c5fb136 100644 (file)
@@ -1,3 +1,12 @@
+2004-06-02  Gert Driesen <drieseng@users.sourceforge.net>
+
+       * OdbcParameter.cs: added missing attributes
+       * OdbcPermission.cs: added missing attributes
+       * OdbcConnection.cs: fixes attribute, added missing attributes
+       * OdbcInfoMessageEventArgs.cs: removed extra properties, fixed
+       API compatibility with MS.NET
+       * OdbcCommandBuilder.cs: use correct attributes
+
 2004-05-20  Gert Driesen (drieseng@users.sourceforge.net)
 
         *  OdbcPermissionAttribute.cs: change AllowMultiple and
index ef01f9fbc5d60439681e2c497dfd018fc32f79a3..1034e1e186285d1c4b639d16bb5f43f7f4c92f17 100644 (file)
@@ -45,7 +45,7 @@ namespace System.Data.Odbc
 
                #region Properties
 
-               [DataSysDescriptionAttribute ("The DataAdapter for which to automatically generate OleDbCommands")]
+               [OdbcDescriptionAttribute ("The DataAdapter for which to automatically generate OdbcCommands")]
                [DefaultValue (null)]
                public OdbcDataAdapter DataAdapter {
                        get {
@@ -57,7 +57,7 @@ namespace System.Data.Odbc
                }
 
                [BrowsableAttribute (false)]
-               [DataSysDescriptionAttribute ("The prefix string wrapped around sql objects")]
+               [OdbcDescriptionAttribute ("The prefix string wrapped around sql objects")]
                 [DesignerSerializationVisibilityAttribute (DesignerSerializationVisibility.Hidden)]
                public string QuotePrefix {
                        get {
@@ -69,7 +69,7 @@ namespace System.Data.Odbc
                }
 
                [BrowsableAttribute (false)]
-                [DataSysDescriptionAttribute ("The suffix string wrapped around sql objects")]
+                [OdbcDescriptionAttribute ("The suffix string wrapped around sql objects")]
                 [DesignerSerializationVisibilityAttribute (DesignerSerializationVisibility.Hidden)]
                public string QuoteSuffix {
                        get {
index 64c09c02c52f545d58e07b606e07fcdd40b6ea3a..dfb9bf93897014d5118982d311a021bb11137dc9 100644 (file)
@@ -59,7 +59,7 @@ namespace System.Data.Odbc
                        get { return hdbc; }
                }
        
-               [DataCategory ("Data")]
+               [OdbcCategoryAttribute ("DataCategory_Data")]           
                [DefaultValue ("")]
                [OdbcDescriptionAttribute ("Information used to connect to a Data Source")]     
                [RefreshPropertiesAttribute (RefreshProperties.All)]
@@ -280,8 +280,12 @@ namespace System.Data.Odbc
 
                #region Events and Delegates
 
+               [OdbcDescription ("DbConnection_StateChange")]
+                [OdbcCategory ("DataCategory_StateChange")]
                public event StateChangeEventHandler StateChange;
 
+               [OdbcDescription ("DbConnection_InfoMessage")]
+                [OdbcCategory ("DataCategory_InfoMessage")]
                public event OdbcInfoMessageEventHandler InfoMessage;
 
                #endregion
index 986a4d1284f90444c1aefd14a4998c00177b5650..396c1d8d107383d7fc8b3a439e79cf1249a1a303 100644 (file)
@@ -23,10 +23,6 @@ namespace System.Data.Odbc
 
                #region Properties
 
-               public int ErrorCode {
-                       [MonoTODO]
-                       get { throw new NotImplementedException (); }
-               }
 
                public OdbcErrorCollection Errors {
                        [MonoTODO]
@@ -38,11 +34,6 @@ namespace System.Data.Odbc
                        get { throw new NotImplementedException (); }
                }
 
-               public string Source {
-                       [MonoTODO]
-                       get { throw new NotImplementedException (); }
-               }
-
                #endregion // Properties
 
                #region Methods
index 6cbd06f954c31f3846743d672bb1f5eba361f79d..24cf0217b275ea20ece1b7273aa376db13cc30cf 100644 (file)
@@ -79,6 +79,7 @@ namespace System.Data.Odbc
                        this.sourceColumn = srcColumn;
                }
 
+               [EditorBrowsable (EditorBrowsableState.Advanced)]
                public OdbcParameter(string name, OdbcType dataType, int size, ParameterDirection direction, bool isNullable, byte precision, byte scale, string srcColumn, DataRowVersion srcVersion, object value)
                        : this (name, dataType, size, srcColumn)
                {
@@ -142,36 +143,57 @@ namespace System.Data.Odbc
                        }
                }
                
+               [OdbcDescription ("DataParameter_ParameterName")]
+                [DefaultValue ("")]    
                public string ParameterName {
                        get { return name; }
                        set { name = value; }
                }
 
+               [OdbcDescription ("DbDataParameter_Precision")]
+                [OdbcCategory ("DataCategory_Data")]
+                [DefaultValue (0)]
                public byte Precision {
                        get { return precision; }
                        set { precision = value; }
                }
                
+                [OdbcDescription ("DbDataParameter_Scale")]
+                [OdbcCategory ("DataCategory_Data")]
+                [DefaultValue (0)]
                public byte Scale {
                        get { return scale; }
                        set { scale = value; }
                }
                
+               [OdbcDescription ("DbDataParameter_Size")]
+                [OdbcCategory ("DataCategory_Data")]
+                [DefaultValue (0)]
                public int Size {
                        get { return size; }
                        set { size = value; }
                }
 
+               [OdbcDescription ("DataParameter_SourceColumn")]
+                [OdbcCategory ("DataCategory_Data")]
+                [DefaultValue ("")]
                public string SourceColumn {
                        get { return sourceColumn; }
                        set { sourceColumn = value; }
                }
                
+                [OdbcDescription ("DataParameter_SourceVersion")]
+                [OdbcCategory ("DataCategory_Data")]
+                [DefaultValue (512)]                   
                public DataRowVersion SourceVersion {
                        get { return sourceVersion; }
                        set { sourceVersion = value; }
                }
-               
+
+               [TypeConverter (typeof(StringConverter))]
+                [OdbcDescription ("DataParameter_Value")]
+                [OdbcCategory ("DataCategory_Data")]
+                [DefaultValue (null)]          
                public object Value {
                        get { 
                                return ParamValue;
index f8b670e9e4a8b4c99d4189e30baef2d271d7d9e8..04aa33aaf8d13073217e4ee712f467d1d4396b70 100644 (file)
@@ -20,12 +20,18 @@ namespace System.Data.Odbc
                #region Constructors
 
                [MonoTODO]
+#if NET_1_1
+               [Obsolete ("use OdbcPermission(PermissionState.None)", true)]
+#endif
                public OdbcPermission () : base (PermissionState.None)
                {
                        throw new NotImplementedException ();
                }
 
                [MonoTODO]
+#if NET_1_1
+               [Obsolete ("use OdbcPermission(PermissionState.None)", true)]
+#endif
                public OdbcPermission (PermissionState state)
                        : base (state)
                {