Просмотр исходного кода

Added files to this namespace

svn path=/trunk/mcs/; revision=49310
Umadevi S 20 лет назад
Родитель
Сommit
62beed1885

+ 8 - 0
mcs/class/System.Data/Microsoft.SqlServer.Server/ChangeLog

@@ -0,0 +1,8 @@
+2005-09-02  Umadevi S <[email protected]>
+
+        * Added files IBinarySerialize.cs,InvalidUdtException.cs,SqlFacetAttribute.cs
+	SqlFunctionAttribute.cs,SqlMetaData.cs, SqlMethodAttribute.cs, SqlUserDefined
+	AggregateAttribute.cs, SqlUserDefinedTypeAttribute.cs, SystemDataAccessKind.cs,
+	TriggerAction.cs
+	(Note these files are moved from System.Data.Sql)
+

+ 49 - 0
mcs/class/System.Data/Microsoft.SqlServer.Server/IBinarySerialize.cs

@@ -0,0 +1,49 @@
+//
+// Microsoft.SqlServer.Server.IBinarySerialize
+//
+// Author:
+//   Tim Coleman ([email protected])
+//
+// Copyright (C) Tim Coleman, 2003
+//
+
+//
+// Copyright (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.IO;
+
+namespace Microsoft.SqlServer.Server {
+	public interface IBinarySerialize 
+	{
+		#region Methods
+
+		void Read (BinaryReader r);
+		void Write (BinaryWriter r);
+
+		#endregion // Methods
+	}
+}
+
+#endif

+ 71 - 0
mcs/class/System.Data/Microsoft.SqlServer.Server/InvalidUdtException.cs

@@ -0,0 +1,71 @@
+//
+// Microsoft.SqlServer.Server.InvalidUdtException
+//
+// Authors:
+//   Tim Coleman ([email protected])
+//   Umadevi S ([email protected])	
+//
+// Copyright (C) Tim Coleman, 2003
+//
+
+//
+// Copyright (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.Runtime.Serialization;
+
+namespace Micrsoft.SqlServer.Server {
+	public sealed class InvalidUdtException : SystemException
+	{
+		#region constructors 
+		
+		[MonoTODO]
+		public InvalidUdtException ()
+		{}
+		
+		[MonoTODO]
+		public InvalidUdtException (string message)	
+		{}
+
+		[MonoTODO]
+		public InvalidUdtException (string message, Exception innerException)
+		{}
+
+		[MonoTODO]
+		public InvalidUdtException (Type t, string reason)
+		{}
+
+		#endregion
+
+
+		#region methods
+
+		[MonoTODO]
+		public override void GetObjectData (SerializationInfo si, StreamingContext context)
+		{}
+		#endregion
+	}
+}
+
+#endif

+ 93 - 0
mcs/class/System.Data/Microsoft.SqlServer.Server/SqlFacetAttribute.cs

@@ -0,0 +1,93 @@
+//
+// Microsoft.SqlServer.Server.SqlFacetAttribute
+//
+// Author:
+//  Umadevi S ([email protected])
+//
+//
+// Copyright (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;
+
+namespace Microsoft.SqlServer.Server {
+	[AttributeUsage (AttributeTargets.Method, AllowMultiple = false, Inherited = false)]
+	[Serializable]
+	public class SqlFacetAttribute : Attribute
+	{
+		#region Fields
+
+		bool isFixedLength;
+		bool isNullable;
+		int maxSize;
+		int precision;
+		int scale;
+
+		#endregion // Fields
+
+		#region Constructors
+
+		public SqlFacetAttribute ()
+		{
+			isFixedLength = false;
+			isNullable = false;
+			maxSize = 0;
+			precision = 0;
+			scale = 0;
+		}
+
+		#endregion // Constructors
+
+		#region Properties
+
+		public bool IsFixedLength {
+			get { return isFixedLength; }
+			set { isFixedLength = value; }
+		}
+		
+		public bool IsNullable {
+			get { return isNullable; }
+			set { isNullable = value; }
+		}
+
+		public int MaxSize {
+			get { return maxSize; }
+			set { maxSize = value; }
+		}
+
+		public int Precision {
+			get { return precision; }
+			set { precision = value; }
+		}
+
+		public int Scale {
+			get { return scale; }
+			set { scale = value; }
+		}
+
+		#endregion // Properties
+	}
+}
+
+#endif

+ 90 - 0
mcs/class/System.Data/Microsoft.SqlServer.Server/SqlFunctionAttribute.cs

@@ -0,0 +1,90 @@
+//
+// Microsoft.SqlServer.Server.SqlFunctionAttribute
+//
+// Author:
+//   Tim Coleman ([email protected])
+//   Umadevi S ([email protected])
+//
+// Copyright (C) Tim Coleman, 2003
+//
+
+//
+// Copyright (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;
+
+namespace Microsoft.SqlServer.Server {
+	[AttributeUsage (AttributeTargets.Method, AllowMultiple = false, Inherited = false)]
+	[Serializable]
+	public class SqlFunctionAttribute : Attribute
+	{
+		#region Fields
+
+		DataAccessKind dataAccess;
+		bool isDeterministic;
+		bool isPrecise;
+		SystemDataAccessKind systemDataAccess;
+
+		#endregion // Fields
+
+		#region Constructors
+
+		public SqlFunctionAttribute ()
+		{
+			dataAccess = DataAccessKind.None;
+			isDeterministic = false;
+			isPrecise = false;
+			systemDataAccess = SystemDataAccessKind.None;
+		}
+
+		#endregion // Constructors
+
+		#region Properties
+
+		public DataAccessKind DataAccess {
+			get { return dataAccess; }
+			set { dataAccess = value; }
+		}
+		
+		public bool IsDeterministic {
+			get { return isDeterministic; }
+			set { isDeterministic = value; }
+		}
+
+		public bool IsPrecise {
+			get { return isPrecise; }
+			set { isPrecise = value; }
+		}
+
+		public SystemDataAccessKind SystemDataAccess {
+			get { return systemDataAccess; }
+			set { systemDataAccess = value; }
+		}
+
+		#endregion // Properties
+	}
+}
+
+#endif

+ 382 - 0
mcs/class/System.Data/Microsoft.SqlServer.Server/SqlMetaData.cs

@@ -0,0 +1,382 @@
+//
+// Microsoft.SqlServer.Server.SqlMetaData
+//
+// Author:
+//   Tim Coleman ([email protected])
+//
+// Copyright (C) Tim Coleman, 2003
+//
+
+//
+// Copyright (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;
+using System.Data.SqlTypes;
+
+namespace Microsoft.SqlServer.Server {
+	public sealed class SqlMetaData
+	{
+		#region Fields
+
+		public const long x_lMax = -1;
+
+		SqlCompareOptions compareOptions = SqlCompareOptions.None;
+		string databaseName = null;
+		bool isPartialLength = false;
+		long localeId = 0L;
+		long maxLength = 4L;
+		string name;
+		byte precision = 10;
+		byte scale = 0;
+		string schemaName = null;
+		SqlDbType sqlDbType = SqlDbType.Int;
+
+		#endregion // Fields
+
+		#region Constructors
+
+		[MonoTODO]
+		public SqlMetaData (string name, SqlDbType type)
+		{
+			this.name = name;
+			this.sqlDbType = type;
+		}
+
+		[MonoTODO]
+		public SqlMetaData (string name, SqlDbType type, long maxLength)
+		{
+			this.maxLength = maxLength;
+			this.name = name;
+			this.sqlDbType = type;
+		}
+
+		[MonoTODO]
+		public SqlMetaData (string name, SqlDbType type, SqlMetaData[] columnMetaData)
+		{
+			this.sqlDbType = type;
+		}
+
+		[MonoTODO]
+		public SqlMetaData (string name, SqlDbType type, byte precision, byte scale)
+		{
+			this.name = name;
+			this.precision = precision;
+			this.scale = scale;
+			this.sqlDbType = type;
+		}
+
+		[MonoTODO]
+		public SqlMetaData (string strName, long maxLength, long localeId, SqlCompareOptions compareOptions, string udtTypeName)
+		{
+			this.compareOptions = compareOptions;
+			this.localeId = localeId;
+			this.maxLength = maxLength;
+			this.name = strName;
+		}
+
+		[MonoTODO]
+		public SqlMetaData (string name, SqlDbType type, long maxLength, long locale, SqlCompareOptions compareOptions)
+		{
+			this.compareOptions = compareOptions;
+			this.localeId = locale;
+			this.maxLength = maxLength;
+			this.name = name;
+			this.sqlDbType = type;
+		}
+
+		[MonoTODO]
+		public SqlMetaData (string name, SqlDbType type, long maxLength, byte precision, byte scale, long localeId, SqlCompareOptions compareOptions, string DatabaseName, string SchemaName, bool PartialLength, string udtTypeName)
+		{
+			this.compareOptions = compareOptions;
+			this.databaseName = DatabaseName;
+			this.isPartialLength = PartialLength;
+			this.localeId = localeId;
+			this.maxLength = maxLength;
+			this.name = name;
+			this.precision = precision;
+			this.scale = scale;
+			this.schemaName = SchemaName;
+			this.sqlDbType = type;
+		}
+
+		#endregion // Constructors
+
+		#region Properties
+
+		public SqlCompareOptions CompareOptions {
+			get { return compareOptions; }
+		}
+
+		public string DatabaseName {
+			get { return databaseName; }
+		}
+
+		[MonoTODO]
+		public DbType DbType {
+			get { throw new NotImplementedException (); }
+		}
+
+		public bool IsPartialLength {
+			get { return isPartialLength; }
+		}
+
+		public long LocaleId {
+			get { return localeId; }
+		}
+
+		public static long MAX {
+			get { return x_lMax; }
+		}
+
+		public long MaxLength {
+			get { return maxLength; }
+		}
+
+		public string Name {
+			get { return name; }
+		}
+
+		public byte Precision { 
+			get { return precision; }
+		}
+
+		public byte Scale { 
+			get { return scale; }
+		}
+
+		public string SchemaName {
+			get { return schemaName; }
+		}
+
+		public SqlDbType SqlDbType {
+			get { return sqlDbType; }
+		}
+
+		[MonoTODO]
+		public string TypeName {
+			get { throw new NotImplementedException (); }
+		}
+
+		#endregion // Properties
+
+		#region Methods
+
+		[MonoTODO]
+		public bool Adjust (bool value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public byte Adjust (byte value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public byte[] Adjust (byte[] value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public char Adjust (char value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public char[] Adjust (char[] value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public DateTime Adjust (DateTime value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public decimal Adjust (decimal value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public double Adjust (double value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public Guid Adjust (Guid value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public short Adjust (short value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public int Adjust (int value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public long Adjust (long value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public object Adjust (object value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public float Adjust (float value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlBinary Adjust (SqlBinary value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlBoolean Adjust (SqlBoolean value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlByte Adjust (SqlByte value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlBytes Adjust (SqlBytes value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlChars Adjust (SqlChars value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlDateTime Adjust (SqlDateTime value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlDecimal Adjust (SqlDecimal value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlDouble Adjust (SqlDouble value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlGuid Adjust (SqlGuid value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlInt16 Adjust (SqlInt16 value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlInt32 Adjust (SqlInt32 value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlInt64 Adjust (SqlInt64 value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlMoney Adjust (SqlMoney value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlSingle Adjust (SqlSingle value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlString Adjust (SqlString value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public string Adjust (string value)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public SqlMetaData GetMetaData (int i)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		[MonoTODO]
+		public static SqlMetaData InferFromValue (object value, string name)
+		{
+			throw new NotImplementedException (); 
+		}
+
+		#endregion // Methods
+	}
+}
+
+#endif

+ 77 - 0
mcs/class/System.Data/Microsoft.SqlServer.Server/SqlMethodAttribute.cs

@@ -0,0 +1,77 @@
+//
+// Microsoft.SqlServer.Server.SqlMethodAttribute
+//
+// Author:
+//   Tim Coleman ([email protected])
+//   Umadevi S ([email protected])
+//
+// Copyright (C) Tim Coleman, 2003
+//
+
+//
+// Copyright (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;
+
+namespace Microsoft.SqlServer.Server {
+	[AttributeUsage (AttributeTargets.Method | AttributeTargets.Property, AllowMultiple = false, Inherited = false)]
+	[Serializable]
+	public sealed class SqlMethodAttribute : SqlFunctionAttribute
+	{
+		#region Fields
+
+		bool isMutator;
+		bool onNullCall;
+
+		#endregion // Fields
+
+		#region Constructors
+
+		public SqlMethodAttribute ()
+			: base ()
+		{
+			isMutator = false;
+			onNullCall = false;
+		}
+
+		#endregion // Constructors
+
+		#region Properties
+
+		public bool IsMutator {
+			get { return isMutator; }
+			set { isMutator = value; }
+		}
+
+		public bool OnNullCall {
+			get { return onNullCall; }
+			set { onNullCall = value; }
+		}
+
+		#endregion // Properties
+	}
+}
+
+#endif

+ 105 - 0
mcs/class/System.Data/Microsoft.SqlServer.Server/SqlUserDefinedAggregateAttribute.cs

@@ -0,0 +1,105 @@
+//
+// Microsoft.SqlServer.Server.SqlUserDefinedAggregateAttribute
+//
+// Author:
+//   Tim Coleman ([email protected])
+//   Umadevi S ([email protected])
+//
+// Copyright (C) Tim Coleman, 2003
+//
+
+//
+// Copyright (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;
+
+namespace Microsoft.SqlServer.Server {
+	[AttributeUsage (AttributeTargets.Class | AttributeTargets.Struct, AllowMultiple = false, Inherited = false)]
+	public sealed class SqlUserDefinedAggregateAttribute : Attribute
+	{
+		#region Fields
+
+		public const int MaxByteSizeValue = 8000;
+
+		Format format;
+		bool isInvariantToDuplicates;
+		bool isInvariantToNulls;
+		bool isInvariantToOrder;
+		bool isNullIfEmpty;
+		int maxByteSize;
+
+		#endregion // Fields
+
+		#region Constructors
+
+		public SqlUserDefinedAggregateAttribute (Format f)
+		{
+			Format = f;
+			IsInvariantToDuplicates = false;
+			IsInvariantToNulls = false;
+			IsInvariantToOrder = false;
+			IsNullIfEmpty = false;
+			MaxByteSize = MaxByteSizeValue;
+		}
+
+		#endregion // Constructors
+
+		#region Properties
+
+		public Format Format { 
+			get { return format; }
+			set { format = value; }
+		}
+
+		public bool IsInvariantToDuplicates {
+			get { return isInvariantToDuplicates; }
+			set { isInvariantToDuplicates = value; }
+		}
+
+		public bool IsInvariantToNulls {
+			get { return isInvariantToNulls; }
+			set { isInvariantToNulls = value; }
+		}
+
+		public bool IsInvariantToOrder {
+			get { return isInvariantToOrder; }
+			set { isInvariantToOrder = value; }
+		}
+
+		public bool IsNullIfEmpty {
+			get { return isNullIfEmpty; }
+			set { isNullIfEmpty = value; }
+		}
+
+		public int MaxByteSize {
+			get { return maxByteSize; }
+			set { maxByteSize = value; }
+		}
+
+		#endregion // Properties
+	}
+}
+
+#endif

+ 91 - 0
mcs/class/System.Data/Microsoft.SqlServer.Server/SqlUserDefinedTypeAttribute.cs

@@ -0,0 +1,91 @@
+//
+// Microsoft.SqlServer.Server.SqlUserDefinedTypeAttribute
+//
+// Author:
+//   Tim Coleman ([email protected])
+//   Umadevi S ([email protected])
+//
+// Copyright (C) Tim Coleman, 2003
+//
+
+//
+// Copyright (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;
+
+namespace Microsoft.SqlServer.Server {
+	[AttributeUsage (AttributeTargets.Class | AttributeTargets.Struct, AllowMultiple = false, Inherited = false)]
+	public sealed class SqlUserDefinedTypeAttribute : Attribute
+	{
+		#region Fields
+
+		public const int MaxByteSizeValue = 8000;
+
+		Format format;
+		bool isByteOrdered;
+		bool isFixedLength;
+		int maxByteSize;
+
+		#endregion // Fields
+
+		#region Constructors
+
+		public SqlUserDefinedTypeAttribute (Format f)
+		{
+			Format = f;
+			IsByteOrdered = false;
+			IsFixedLength = false;
+			MaxByteSize = MaxByteSizeValue;
+		}
+
+		#endregion // Constructors
+
+		#region Properties
+
+		public Format Format { 
+			get { return format; }
+			set { format = value; }
+		}
+
+		public bool IsByteOrdered {
+			get { return isByteOrdered; }
+			set { isByteOrdered = value; }
+		}
+
+		public bool IsFixedLength {
+			get { return isFixedLength; }
+			set { isFixedLength = value; }
+		}
+
+		public int MaxByteSize {
+			get { return maxByteSize; }
+			set { maxByteSize = value; }
+		}
+
+		#endregion // Properties
+	}
+}
+
+#endif

+ 44 - 0
mcs/class/System.Data/Microsoft.SqlServer.Server/SystemDataAccessKind.cs

@@ -0,0 +1,44 @@
+//
+// Microsoft.SqlServer.Server.SystemDataAccessKind
+//
+// Author:
+//   Tim Coleman ([email protected])
+//   Umadevi S ([email protected])
+//
+// Copyright (C) Tim Coleman, 2003
+//
+
+//
+// Copyright (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
+
+namespace Microsoft.SqlServer.Server {
+	public enum SystemDataAccessKind
+	{
+		None,
+		Read
+	}
+}
+
+#endif

+ 116 - 0
mcs/class/System.Data/Microsoft.SqlServer.Server/TriggerAction.cs

@@ -0,0 +1,116 @@
+//
+// Microsoft.SqlServer.Server.TriggerAction
+//
+// Authors:
+//   Tim Coleman ([email protected])
+//   Umadevi S ([email protected])
+//
+// Copyright (C) Tim Coleman, 2003
+//
+//
+// Copyright (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
+
+namespace Microsoft.SqlServer.Server {
+	public enum TriggerAction
+	{
+		AlterAppRole = 138,
+		AlterAssembly = 102,
+		AlterBinding = 175,
+		AlterFunction = 62,
+		AlterIndex = 25,
+		AlterLogin = 145,
+		AlterPartitionFunction = 192,
+		AlterPartitionScheme = 195,
+		AlterProcedure = 52,
+		AlterQueue = 158,
+		AlterRole = 135,
+		AlterRoute = 165,
+		AlterSchema = 142,
+		AlterService = 162,
+		AlterTable = 22,
+		AlterTrigger = 72,
+		AlterUser = 132,
+		AlterView = 42,
+		CreateAppRole = 137,
+		CreateAssembly = 101,
+		CreateBinding = 174,
+		CreateContract = 154,
+		CreateEventNotification = 74,
+		CreateFunction = 61,
+		CreateIndex = 24,
+		CreateLogin = 144,
+		CreateMsgType = 151,
+		CreatePartitionFunction = 191,
+		CreatePartitionScheme = 194,
+		CreateProcedure = 51,
+		CreateQueue = 157,
+		CreateRole = 134,
+		CreateRoute = 164,
+		CreateSchema = 141,
+		CreateSecexpr = 31,
+		CreateService = 161,
+		CreateSynonym = 34,
+		CreateTable = 21,
+		CreateTrigger = 71,
+		CreateType = 91,
+		CreateUser = 131,
+		CreateView = 41,
+		Delete = 3,
+		DenyObject = 171,
+		DropAppRole = 139,
+		DropAssembly = 103,
+		DropBinding = 176,
+		DropContract = 156,
+		DropEventNotification = 76,
+		DropFunction = 63,
+		DropIndex = 26,
+		DropLogin = 146,
+		DropMsgType = 153,
+		DropPartitionFunction = 193,
+		DropPartitionScheme = 196,
+		DropProcedure = 53,
+		DropQueue = 159,
+		DropRole = 136,
+		DropRoute = 166,
+		DropSchema = 143,
+		DropSecexpr = 33,
+		DropService = 163,
+		DropSynonym = 36,
+		DropTable = 23,
+		DropTrigger = 73,
+		DropType = 93,
+		DropUser = 133,
+		DropView = 43,
+		GrantObject = 170,
+		GrantStatement = 167,
+		Insert = 1,
+		Invalid = 0,
+		RevokeObject = 172,
+		RevokeStatement = 169,
+		Update = 2
+	}
+}
+
+#endif