2004-04-22 Martin Baulig <martin@ximian.com>
[mono.git] / mcs / class / System.Data / System.Data.SqlTypes / SqlXmlReader.cs
1 //
2 // System.Data.SqlTypes.SqlXmlReader
3 //
4 // Author:
5 //   Tim Coleman <tim@timcoleman.com>
6 //
7 // Copyright (C) Tim Coleman, 2003
8 //
9
10 #if NET_2_0
11
12 using System;
13 using System.Globalization;
14 using System.Xml;
15
16 namespace System.Data.SqlTypes
17 {
18         [MonoTODO]
19         public struct SqlXmlReader : INullable, IComparable
20         {
21                 #region Fields
22
23                 public static readonly SqlXmlReader Null;
24
25                 bool notNull;
26
27                 #endregion
28
29                 #region Constructors
30
31                 [MonoTODO]
32                 public SqlXmlReader (XmlReader value)
33                 {
34                         notNull = true;
35                 }
36
37                 #endregion
38
39                 #region Properties
40
41                 public bool IsNull {
42                         get { return !notNull; }
43                 }
44
45                 #endregion
46
47                 #region Methods
48
49                 public int CompareTo (object value)
50                 {
51                         if (value == null)
52                                 return 1;
53                         else if (!(value is SqlXmlReader))   
54                                 throw new ArgumentException (Locale.GetText ("Value is not a System.Data.SqlTypes.SqlXmlReader"));
55                         else if (((SqlXmlReader)value).IsNull)
56                                 return 1;
57                         else
58                                 throw new NotImplementedException ();
59                 }
60
61                 #endregion
62         }
63 }
64
65 #endif