2 // System.Data.DataTableReader.cs
5 // Tim Coleman (tim@timcoleman.com)
7 // Copyright (C) Tim Coleman, 2003
12 using System.Collections;
13 using System.Data.Common;
15 namespace System.Data {
16 public sealed class DataTableReader : DbDataReader
19 DataTable[] dataTables;
25 public DataTableReader (DataTable dt)
26 : this (new DataTable[] {dt})
31 public DataTableReader (DataTable[] dataTables)
33 this.dataTables = dataTables;
38 #endregion // Constructors
42 public override int Depth {
46 public override int FieldCount {
47 get { return dataTables [index].Columns.Count; }
50 public override bool HasRows {
51 get { return dataTables [index].Rows.Count > 0; }
54 public override bool IsClosed {
55 get { return closed; }
59 public override object this [int index] {
60 get { throw new NotImplementedException (); }
64 public override object this [string name] {
65 get { throw new NotImplementedException (); }
69 public override int RecordsAffected {
70 get { throw new NotImplementedException (); }
74 public override int VisibleFieldCount {
75 get { throw new NotImplementedException (); }
78 #endregion // Properties
83 public override void Close ()
89 public override void Dispose ()
91 throw new NotImplementedException ();
95 public override bool GetBoolean (int i)
97 throw new NotImplementedException ();
101 public override byte GetByte (int i)
103 throw new NotImplementedException ();
107 public override long GetBytes (int i, long dataIndex, byte[] buffer, int bufferIndex, int length)
109 throw new NotImplementedException ();
113 public override char GetChar (int i)
115 throw new NotImplementedException ();
119 public override long GetChars (int i, long dataIndex, char[] buffer, int bufferIndex, int length)
121 throw new NotImplementedException ();
125 public override string GetDataTypeName (int i)
127 throw new NotImplementedException ();
131 public override DateTime GetDateTime (int i)
133 throw new NotImplementedException ();
137 public override decimal GetDecimal (int i)
139 throw new NotImplementedException ();
143 public override double GetDouble (int i)
145 throw new NotImplementedException ();
149 public override IEnumerator GetEnumerator ()
151 throw new NotImplementedException ();
155 public override Type GetFieldProviderSpecificType (int i)
157 throw new NotImplementedException ();
161 public override Type GetFieldType (int i)
163 throw new NotImplementedException ();
167 public override float GetFloat (int i)
169 throw new NotImplementedException ();
173 public override Guid GetGuid (int i)
175 throw new NotImplementedException ();
179 public override short GetInt16 (int i)
181 throw new NotImplementedException ();
185 public override int GetInt32 (int i)
187 throw new NotImplementedException ();
191 public override long GetInt64 (int i)
193 throw new NotImplementedException ();
197 public override string GetName (int i)
199 throw new NotImplementedException ();
203 public override int GetOrdinal (string name)
205 throw new NotImplementedException ();
209 public override object GetProviderSpecificValue (int i)
211 throw new NotImplementedException ();
215 public override int GetProviderSpecificValues (object[] values)
217 throw new NotImplementedException ();
221 public override DataTable GetSchemaTable ()
223 throw new NotImplementedException ();
227 public override string GetString (int i)
229 throw new NotImplementedException ();
233 public override object GetValue (int i)
235 throw new NotImplementedException ();
239 public override int GetValues (object[] values)
241 throw new NotImplementedException ();
245 public override bool IsDBNull (int i)
247 throw new NotImplementedException ();
251 public override bool NextResult ()
253 throw new NotImplementedException ();
257 public override bool Read ()
259 throw new NotImplementedException ();
262 #endregion // Methods