CSLA.NET 5.4.2
CSLA .NET is a software development framework that helps you build a reusable, maintainable object-oriented business layer for your app.
Csla.Data.SafeDataReader Class Reference

This is an IDataReader that 'fixes' any null values before they are returned to our business code. More...

Inheritance diagram for Csla.Data.SafeDataReader:
Csla.Data.SqlClient.SafeSqlDataReader

Public Member Functions

 SafeDataReader (IDataReader dataReader)
 Initializes the SafeDataReader object to use data from the provided DataReader object. More...
 
Task< T > GetFieldValueAsync< T > (int ordinal)
 Asynchronously gets the data value as a type. More...
 
Task< T > GetFieldValueAsync< T > (int ordinal, System.Threading.CancellationToken cancellationToken)
 Asynchronously gets the data value as a type. More...
 
Task< bool > IsDbNullAsync (int ordinal)
 Gets a value indicating whether the column has a null or missing value. More...
 
Task< bool > IsDbNullAsync (int ordinal, System.Threading.CancellationToken cancellationToken)
 Gets a value indicating whether the column has a null or missing value. More...
 
Task< bool > NextResultAsync ()
 Advances the reader to the next result. More...
 
Task< bool > NextResultAsync (System.Threading.CancellationToken cancellationToken)
 Advances the reader to the next result. More...
 
Task< bool > ReadAsync ()
 Advances to the next record in a recordset. More...
 
Task< bool > ReadAsync (System.Threading.CancellationToken cancellationToken)
 Advances to the next record in a recordset. More...
 
string GetString (string name)
 Gets a string value from the datareader. More...
 
virtual string GetString (int i)
 Gets a string value from the datareader. More...
 
object GetValue (string name)
 Gets a value of type System.Object from the datareader. More...
 
virtual object GetValue (int i)
 Gets a value of type System.Object from the datareader. More...
 
int GetInt32 (string name)
 Gets an integer from the datareader. More...
 
virtual int GetInt32 (int i)
 Gets an integer from the datareader. More...
 
double GetDouble (string name)
 Gets a double from the datareader. More...
 
virtual double GetDouble (int i)
 Gets a double from the datareader. More...
 
Csla.SmartDate GetSmartDate (string name)
 Gets a SmartDate from the datareader. More...
 
virtual Csla.SmartDate GetSmartDate (int i)
 Gets a SmartDate from the datareader. More...
 
Csla.SmartDate GetSmartDate (string name, bool minIsEmpty)
 Gets a SmartDate from the datareader. More...
 
virtual Csla.SmartDate GetSmartDate (int i, bool minIsEmpty)
 Gets a SmartDate from the datareader. More...
 
System.Guid GetGuid (string name)
 Gets a Guid value from the datareader. More...
 
virtual System.Guid GetGuid (int i)
 Gets a Guid value from the datareader. More...
 
bool Read ()
 Reads the next row of data from the datareader. More...
 
bool NextResult ()
 Moves to the next result set in the datareader. More...
 
void Close ()
 Closes the datareader. More...
 
bool GetBoolean (string name)
 Gets a boolean value from the datareader. More...
 
virtual bool GetBoolean (int i)
 Gets a boolean value from the datareader. More...
 
byte GetByte (string name)
 Gets a byte value from the datareader. More...
 
virtual byte GetByte (int i)
 Gets a byte value from the datareader. More...
 
Int64 GetBytes (string name, Int64 fieldOffset, byte[] buffer, int bufferOffset, int length)
 Invokes the GetBytes method of the underlying datareader. More...
 
virtual Int64 GetBytes (int i, Int64 fieldOffset, byte[] buffer, int bufferOffset, int length)
 Invokes the GetBytes method of the underlying datareader. More...
 
char GetChar (string name)
 Gets a char value from the datareader. More...
 
virtual char GetChar (int i)
 Gets a char value from the datareader. More...
 
Int64 GetChars (string name, Int64 fieldOffset, char[] buffer, int bufferOffset, int length)
 Invokes the GetChars method of the underlying datareader. More...
 
virtual Int64 GetChars (int i, Int64 fieldOffset, char[] buffer, int bufferOffset, int length)
 Invokes the GetChars method of the underlying datareader. More...
 
IDataReader GetData (string name)
 Invokes the GetData method of the underlying datareader. More...
 
virtual IDataReader GetData (int i)
 Invokes the GetData method of the underlying datareader. More...
 
string GetDataTypeName (string name)
 Invokes the GetDataTypeName method of the underlying datareader. More...
 
virtual string GetDataTypeName (int i)
 Invokes the GetDataTypeName method of the underlying datareader. More...
 
virtual DateTime GetDateTime (string name)
 Gets a date value from the datareader. More...
 
virtual DateTime GetDateTime (int i)
 Gets a date value from the datareader. More...
 
virtual DateTimeOffset GetDateTimeOffset (string name)
 Gets an UTC date value from the datareader. More...
 
virtual DateTimeOffset GetDateTimeOffset (int i)
 Gets an UTC date value from the datareader. More...
 
decimal GetDecimal (string name)
 Gets a decimal value from the datareader. More...
 
virtual decimal GetDecimal (int i)
 Gets a decimal value from the datareader. More...
 
Type GetFieldType (string name)
 Invokes the GetFieldType method of the underlying datareader. More...
 
virtual Type GetFieldType (int i)
 Invokes the GetFieldType method of the underlying datareader. More...
 
float GetFloat (string name)
 Gets a Single value from the datareader. More...
 
virtual float GetFloat (int i)
 Gets a Single value from the datareader. More...
 
short GetInt16 (string name)
 Gets a Short value from the datareader. More...
 
virtual short GetInt16 (int i)
 Gets a Short value from the datareader. More...
 
Int64 GetInt64 (string name)
 Gets a Long value from the datareader. More...
 
virtual Int64 GetInt64 (int i)
 Gets a Long value from the datareader. More...
 
virtual string GetName (int i)
 Invokes the GetName method of the underlying datareader. More...
 
int GetOrdinal (string name)
 Gets an ordinal value from the datareader. More...
 
DataTable GetSchemaTable ()
 Invokes the GetSchemaTable method of the underlying datareader. More...
 
int GetValues (object[] values)
 Invokes the GetValues method of the underlying datareader. More...
 
virtual bool IsDBNull (int i)
 Invokes the IsDBNull method of the underlying datareader. More...
 
virtual bool IsDBNull (string name)
 Invokes the IsDBNull method of the underlying datareader. More...
 
void Dispose ()
 Disposes the object. More...
 

Protected Member Functions

virtual void Dispose (bool disposing)
 Disposes the object. More...
 

Properties

IDataReader DataReader [get]
 Get a reference to the underlying data reader object that actually contains the data from the data source. More...
 
int Depth [get]
 Returns the depth property value from the datareader. More...
 
int FieldCount [get]
 Returns the FieldCount property from the datareader. More...
 
bool IsClosed [get]
 Returns the IsClosed property value from the datareader. More...
 
object this[string name] [get]
 Returns a value from the datareader. More...
 
virtual object this[int i] [get]
 Returns a value from the datareader. More...
 
int RecordsAffected [get]
 Returns the RecordsAffected property value from the underlying datareader. More...
 

Detailed Description

This is an IDataReader that 'fixes' any null values before they are returned to our business code.

Definition at line 21 of file SafeDataReader.cs.

Constructor & Destructor Documentation

◆ SafeDataReader()

Csla.Data.SafeDataReader.SafeDataReader ( IDataReader  dataReader)

Initializes the SafeDataReader object to use data from the provided DataReader object.

Parameters
dataReaderThe source DataReader object containing the data.

Definition at line 39 of file SafeDataReader.cs.

Member Function Documentation

◆ Close()

void Csla.Data.SafeDataReader.Close ( )

Closes the datareader.

Definition at line 357 of file SafeDataReader.cs.

◆ Dispose() [1/2]

void Csla.Data.SafeDataReader.Dispose ( )

Disposes the object.

Definition at line 894 of file SafeDataReader.cs.

◆ Dispose() [2/2]

virtual void Csla.Data.SafeDataReader.Dispose ( bool  disposing)
protectedvirtual

Disposes the object.

Parameters
disposingTrue if called by the public Dispose method.

Definition at line 876 of file SafeDataReader.cs.

◆ GetBoolean() [1/2]

virtual bool Csla.Data.SafeDataReader.GetBoolean ( int  i)
virtual

Gets a boolean value from the datareader.

Returns false for null.

Parameters
iOrdinal column position of the value.

Definition at line 403 of file SafeDataReader.cs.

◆ GetBoolean() [2/2]

bool Csla.Data.SafeDataReader.GetBoolean ( string  name)

Gets a boolean value from the datareader.

Returns false for null.

Parameters
nameName of the column containing the value.

Definition at line 391 of file SafeDataReader.cs.

◆ GetByte() [1/2]

virtual byte Csla.Data.SafeDataReader.GetByte ( int  i)
virtual

Gets a byte value from the datareader.

Returns 0 for null.

Parameters
iOrdinal column position of the value.

Definition at line 430 of file SafeDataReader.cs.

◆ GetByte() [2/2]

byte Csla.Data.SafeDataReader.GetByte ( string  name)

Gets a byte value from the datareader.

Returns 0 for null.

Parameters
nameName of the column containing the value.

Definition at line 418 of file SafeDataReader.cs.

◆ GetBytes() [1/2]

virtual Int64 Csla.Data.SafeDataReader.GetBytes ( int  i,
Int64  fieldOffset,
byte[]  buffer,
int  bufferOffset,
int  length 
)
virtual

Invokes the GetBytes method of the underlying datareader.

Returns 0 for null.

Parameters
iOrdinal column position of the value.
bufferArray containing the data.
bufferOffsetOffset position within the buffer.
fieldOffsetOffset position within the field.
lengthLength of data to read.

Definition at line 466 of file SafeDataReader.cs.

◆ GetBytes() [2/2]

Int64 Csla.Data.SafeDataReader.GetBytes ( string  name,
Int64  fieldOffset,
byte[]  buffer,
int  bufferOffset,
int  length 
)

Invokes the GetBytes method of the underlying datareader.

Returns 0 for null.

Parameters
nameName of the column containing the value.
bufferArray containing the data.
bufferOffsetOffset position within the buffer.
fieldOffsetOffset position within the field.
lengthLength of data to read.

Definition at line 449 of file SafeDataReader.cs.

◆ GetChar() [1/2]

virtual char Csla.Data.SafeDataReader.GetChar ( int  i)
virtual

Gets a char value from the datareader.

Returns Char.MinValue for null.

Parameters
iOrdinal column position of the value.

Definition at line 494 of file SafeDataReader.cs.

◆ GetChar() [2/2]

char Csla.Data.SafeDataReader.GetChar ( string  name)

Gets a char value from the datareader.

Returns Char.MinValue for null.

Parameters
nameName of the column containing the value.

Definition at line 482 of file SafeDataReader.cs.

◆ GetChars() [1/2]

virtual Int64 Csla.Data.SafeDataReader.GetChars ( int  i,
Int64  fieldOffset,
char[]  buffer,
int  bufferOffset,
int  length 
)
virtual

Invokes the GetChars method of the underlying datareader.

Returns 0 for null.

Parameters
iOrdinal column position of the value.
bufferArray containing the data.
bufferOffsetOffset position within the buffer.
fieldOffsetOffset position within the field.
lengthLength of data to read.

Definition at line 534 of file SafeDataReader.cs.

◆ GetChars() [2/2]

Int64 Csla.Data.SafeDataReader.GetChars ( string  name,
Int64  fieldOffset,
char[]  buffer,
int  bufferOffset,
int  length 
)

Invokes the GetChars method of the underlying datareader.

Returns 0 for null.

Parameters
nameName of the column containing the value.
bufferArray containing the data.
bufferOffsetOffset position within the buffer.
fieldOffsetOffset position within the field.
lengthLength of data to read.

Definition at line 517 of file SafeDataReader.cs.

◆ GetData() [1/2]

virtual IDataReader Csla.Data.SafeDataReader.GetData ( int  i)
virtual

Invokes the GetData method of the underlying datareader.

Parameters
iOrdinal column position of the value.

Definition at line 556 of file SafeDataReader.cs.

◆ GetData() [2/2]

IDataReader Csla.Data.SafeDataReader.GetData ( string  name)

Invokes the GetData method of the underlying datareader.

Parameters
nameName of the column containing the value.

Definition at line 547 of file SafeDataReader.cs.

◆ GetDataTypeName() [1/2]

virtual string Csla.Data.SafeDataReader.GetDataTypeName ( int  i)
virtual

Invokes the GetDataTypeName method of the underlying datareader.

Parameters
iOrdinal column position of the value.

Definition at line 574 of file SafeDataReader.cs.

◆ GetDataTypeName() [2/2]

string Csla.Data.SafeDataReader.GetDataTypeName ( string  name)

Invokes the GetDataTypeName method of the underlying datareader.

Parameters
nameName of the column containing the value.

Definition at line 565 of file SafeDataReader.cs.

◆ GetDateTime() [1/2]

virtual DateTime Csla.Data.SafeDataReader.GetDateTime ( int  i)
virtual

Gets a date value from the datareader.

Returns DateTime.MinValue for null.

Parameters
iOrdinal column position of the value.

Definition at line 598 of file SafeDataReader.cs.

◆ GetDateTime() [2/2]

virtual DateTime Csla.Data.SafeDataReader.GetDateTime ( string  name)
virtual

Gets a date value from the datareader.

Returns DateTime.MinValue for null.

Parameters
nameName of the column containing the value.

Definition at line 586 of file SafeDataReader.cs.

◆ GetDateTimeOffset() [1/2]

virtual DateTimeOffset Csla.Data.SafeDataReader.GetDateTimeOffset ( int  i)
virtual

Gets an UTC date value from the datareader.

Returns DateTimeOffset.MinValue for null.

Parameters
iOrdinal column position of the value.

Definition at line 625 of file SafeDataReader.cs.

◆ GetDateTimeOffset() [2/2]

virtual DateTimeOffset Csla.Data.SafeDataReader.GetDateTimeOffset ( string  name)
virtual

Gets an UTC date value from the datareader.

Returns DateTimeOffset.MinValue for null.

Parameters
nameName of the column containing the value.

Definition at line 613 of file SafeDataReader.cs.

◆ GetDecimal() [1/2]

virtual decimal Csla.Data.SafeDataReader.GetDecimal ( int  i)
virtual

Gets a decimal value from the datareader.

Returns 0 for null.

Parameters
iOrdinal column position of the value.

Definition at line 652 of file SafeDataReader.cs.

◆ GetDecimal() [2/2]

decimal Csla.Data.SafeDataReader.GetDecimal ( string  name)

Gets a decimal value from the datareader.

Returns 0 for null.

Parameters
nameName of the column containing the value.

Definition at line 640 of file SafeDataReader.cs.

◆ GetDouble() [1/2]

virtual double Csla.Data.SafeDataReader.GetDouble ( int  i)
virtual

Gets a double from the datareader.

Returns 0 for null.

Parameters
iOrdinal column position of the value.

Definition at line 243 of file SafeDataReader.cs.

◆ GetDouble() [2/2]

double Csla.Data.SafeDataReader.GetDouble ( string  name)

Gets a double from the datareader.

Returns 0 for null.

Parameters
nameName of the column containing the value.

Definition at line 231 of file SafeDataReader.cs.

◆ GetFieldType() [1/2]

virtual Type Csla.Data.SafeDataReader.GetFieldType ( int  i)
virtual

Invokes the GetFieldType method of the underlying datareader.

Parameters
iOrdinal column position of the value.

Definition at line 673 of file SafeDataReader.cs.

◆ GetFieldType() [2/2]

Type Csla.Data.SafeDataReader.GetFieldType ( string  name)

Invokes the GetFieldType method of the underlying datareader.

Parameters
nameName of the column containing the value.

Definition at line 664 of file SafeDataReader.cs.

◆ GetFieldValueAsync< T >() [1/2]

Task< T > Csla.Data.SafeDataReader.GetFieldValueAsync< T > ( int  ordinal)

Asynchronously gets the data value as a type.

Template Parameters
TType of value
Parameters
ordinalOrdinal position of value
Returns

Definition at line 54 of file SafeDataReader.cs.

◆ GetFieldValueAsync< T >() [2/2]

Task< T > Csla.Data.SafeDataReader.GetFieldValueAsync< T > ( int  ordinal,
System.Threading.CancellationToken  cancellationToken 
)

Asynchronously gets the data value as a type.

Template Parameters
TType of value
Parameters
ordinalOrdinal position of value
cancellationTokenAsync cancellation token

Definition at line 67 of file SafeDataReader.cs.

◆ GetFloat() [1/2]

virtual float Csla.Data.SafeDataReader.GetFloat ( int  i)
virtual

Gets a Single value from the datareader.

Returns 0 for null.

Parameters
iOrdinal column position of the value.

Definition at line 697 of file SafeDataReader.cs.

◆ GetFloat() [2/2]

float Csla.Data.SafeDataReader.GetFloat ( string  name)

Gets a Single value from the datareader.

Returns 0 for null.

Parameters
nameName of the column containing the value.

Definition at line 685 of file SafeDataReader.cs.

◆ GetGuid() [1/2]

virtual System.Guid Csla.Data.SafeDataReader.GetGuid ( int  i)
virtual

Gets a Guid value from the datareader.

Returns Guid.Empty for null.

Parameters
iOrdinal column position of the value.

Definition at line 330 of file SafeDataReader.cs.

◆ GetGuid() [2/2]

System.Guid Csla.Data.SafeDataReader.GetGuid ( string  name)

Gets a Guid value from the datareader.

Returns Guid.Empty for null.

Parameters
nameName of the column containing the value.

Definition at line 318 of file SafeDataReader.cs.

◆ GetInt16() [1/2]

virtual short Csla.Data.SafeDataReader.GetInt16 ( int  i)
virtual

Gets a Short value from the datareader.

Returns 0 for null.

Parameters
iOrdinal column position of the value.

Definition at line 724 of file SafeDataReader.cs.

◆ GetInt16() [2/2]

short Csla.Data.SafeDataReader.GetInt16 ( string  name)

Gets a Short value from the datareader.

Returns 0 for null.

Parameters
nameName of the column containing the value.

Definition at line 712 of file SafeDataReader.cs.

◆ GetInt32() [1/2]

virtual int Csla.Data.SafeDataReader.GetInt32 ( int  i)
virtual

Gets an integer from the datareader.

Returns 0 for null.

Parameters
iOrdinal column position of the value.

Definition at line 216 of file SafeDataReader.cs.

◆ GetInt32() [2/2]

int Csla.Data.SafeDataReader.GetInt32 ( string  name)

Gets an integer from the datareader.

Returns 0 for null.

Parameters
nameName of the column containing the value.

Definition at line 204 of file SafeDataReader.cs.

◆ GetInt64() [1/2]

virtual Int64 Csla.Data.SafeDataReader.GetInt64 ( int  i)
virtual

Gets a Long value from the datareader.

Returns 0 for null.

Parameters
iOrdinal column position of the value.

Definition at line 751 of file SafeDataReader.cs.

◆ GetInt64() [2/2]

Int64 Csla.Data.SafeDataReader.GetInt64 ( string  name)

Gets a Long value from the datareader.

Returns 0 for null.

Parameters
nameName of the column containing the value.

Definition at line 739 of file SafeDataReader.cs.

◆ GetName()

virtual string Csla.Data.SafeDataReader.GetName ( int  i)
virtual

Invokes the GetName method of the underlying datareader.

Parameters
iOrdinal column position of the value.

Definition at line 763 of file SafeDataReader.cs.

◆ GetOrdinal()

int Csla.Data.SafeDataReader.GetOrdinal ( string  name)

Gets an ordinal value from the datareader.

Parameters
nameName of the column containing the value.

Definition at line 772 of file SafeDataReader.cs.

◆ GetSchemaTable()

DataTable Csla.Data.SafeDataReader.GetSchemaTable ( )

Invokes the GetSchemaTable method of the underlying datareader.

Definition at line 780 of file SafeDataReader.cs.

◆ GetSmartDate() [1/4]

virtual Csla.SmartDate Csla.Data.SafeDataReader.GetSmartDate ( int  i)
virtual

Gets a SmartDate from the datareader.

A null is converted into the min possible date See Chapter 5 for more details on the SmartDate class.

Parameters
iOrdinal column position of the value.

Definition at line 272 of file SafeDataReader.cs.

◆ GetSmartDate() [2/4]

virtual Csla.SmartDate Csla.Data.SafeDataReader.GetSmartDate ( int  i,
bool  minIsEmpty 
)
virtual

Gets a SmartDate from the datareader.

Parameters
iOrdinal column position of the value.
minIsEmptyA flag indicating whether the min or max value of a data means an empty date.

Definition at line 301 of file SafeDataReader.cs.

◆ GetSmartDate() [3/4]

Csla.SmartDate Csla.Data.SafeDataReader.GetSmartDate ( string  name)

Gets a SmartDate from the datareader.

A null is converted into min possible date See Chapter 5 for more details on the SmartDate class.

Parameters
nameName of the column containing the value.

Definition at line 259 of file SafeDataReader.cs.

◆ GetSmartDate() [4/4]

Csla.SmartDate Csla.Data.SafeDataReader.GetSmartDate ( string  name,
bool  minIsEmpty 
)

Gets a SmartDate from the datareader.

A null is converted into either the min or max possible date depending on the MinIsEmpty parameter. See Chapter 5 for more details on the SmartDate class.

Parameters
nameName of the column containing the value.
minIsEmptyA flag indicating whether the min or max value of a data means an empty date.

Definition at line 289 of file SafeDataReader.cs.

◆ GetString() [1/2]

virtual string Csla.Data.SafeDataReader.GetString ( int  i)
virtual

Gets a string value from the datareader.

Returns empty string for null.

Parameters
iOrdinal column position of the value.

Definition at line 167 of file SafeDataReader.cs.

◆ GetString() [2/2]

string Csla.Data.SafeDataReader.GetString ( string  name)

Gets a string value from the datareader.

Returns empty string for null.

Parameters
nameName of the column containing the value.

Definition at line 155 of file SafeDataReader.cs.

◆ GetValue() [1/2]

virtual object Csla.Data.SafeDataReader.GetValue ( int  i)
virtual

Gets a value of type System.Object from the datareader.

Parameters
iOrdinal column position of the value.

Definition at line 189 of file SafeDataReader.cs.

◆ GetValue() [2/2]

object Csla.Data.SafeDataReader.GetValue ( string  name)

Gets a value of type System.Object from the datareader.

Parameters
nameName of the column containing the value.

Definition at line 180 of file SafeDataReader.cs.

◆ GetValues()

int Csla.Data.SafeDataReader.GetValues ( object[]  values)

Invokes the GetValues method of the underlying datareader.

Parameters
valuesAn array of System.Object to copy the values into.

Definition at line 791 of file SafeDataReader.cs.

◆ IsDBNull() [1/2]

virtual bool Csla.Data.SafeDataReader.IsDBNull ( int  i)
virtual

Invokes the IsDBNull method of the underlying datareader.

Parameters
iOrdinal column position of the value.

Definition at line 811 of file SafeDataReader.cs.

◆ IsDBNull() [2/2]

virtual bool Csla.Data.SafeDataReader.IsDBNull ( string  name)
virtual

Invokes the IsDBNull method of the underlying datareader.

Parameters
nameName of the column containing the value.

Definition at line 820 of file SafeDataReader.cs.

◆ IsDbNullAsync() [1/2]

Task< bool > Csla.Data.SafeDataReader.IsDbNullAsync ( int  ordinal)

Gets a value indicating whether the column has a null or missing value.

Parameters
ordinalOrdinal position of value
Returns

Definition at line 80 of file SafeDataReader.cs.

◆ IsDbNullAsync() [2/2]

Task< bool > Csla.Data.SafeDataReader.IsDbNullAsync ( int  ordinal,
System.Threading.CancellationToken  cancellationToken 
)

Gets a value indicating whether the column has a null or missing value.

Parameters
ordinalOrdinal position of value
cancellationTokenAsync cancellation token
Returns

Definition at line 94 of file SafeDataReader.cs.

◆ NextResult()

bool Csla.Data.SafeDataReader.NextResult ( )

Moves to the next result set in the datareader.

Definition at line 349 of file SafeDataReader.cs.

◆ NextResultAsync() [1/2]

Task< bool > Csla.Data.SafeDataReader.NextResultAsync ( )

Advances the reader to the next result.

Returns

Definition at line 105 of file SafeDataReader.cs.

◆ NextResultAsync() [2/2]

Task< bool > Csla.Data.SafeDataReader.NextResultAsync ( System.Threading.CancellationToken  cancellationToken)

Advances the reader to the next result.

Parameters
cancellationTokenAsync cancellation token
Returns

Definition at line 117 of file SafeDataReader.cs.

◆ Read()

bool Csla.Data.SafeDataReader.Read ( )

Reads the next row of data from the datareader.

Definition at line 341 of file SafeDataReader.cs.

◆ ReadAsync() [1/2]

Task< bool > Csla.Data.SafeDataReader.ReadAsync ( )

Advances to the next record in a recordset.

Returns

Definition at line 128 of file SafeDataReader.cs.

◆ ReadAsync() [2/2]

Task< bool > Csla.Data.SafeDataReader.ReadAsync ( System.Threading.CancellationToken  cancellationToken)

Advances to the next record in a recordset.

Parameters
cancellationTokenAsync cancellation token
Returns

Definition at line 140 of file SafeDataReader.cs.

Property Documentation

◆ DataReader

IDataReader Csla.Data.SafeDataReader.DataReader
getprotected

Get a reference to the underlying data reader object that actually contains the data from the data source.

Definition at line 32 of file SafeDataReader.cs.

◆ Depth

int Csla.Data.SafeDataReader.Depth
get

Returns the depth property value from the datareader.

Definition at line 365 of file SafeDataReader.cs.

◆ FieldCount

int Csla.Data.SafeDataReader.FieldCount
get

Returns the FieldCount property from the datareader.

Definition at line 376 of file SafeDataReader.cs.

◆ IsClosed

bool Csla.Data.SafeDataReader.IsClosed
get

Returns the IsClosed property value from the datareader.

Definition at line 799 of file SafeDataReader.cs.

◆ RecordsAffected

int Csla.Data.SafeDataReader.RecordsAffected
get

Returns the RecordsAffected property value from the underlying datareader.

Definition at line 859 of file SafeDataReader.cs.

◆ this[int i]

virtual object Csla.Data.SafeDataReader.this[int i]
get

Returns a value from the datareader.

Parameters
iOrdinal column position of the value.

Definition at line 846 of file SafeDataReader.cs.

◆ this[string name]

object Csla.Data.SafeDataReader.this[string name]
get

Returns a value from the datareader.

Parameters
nameName of the column containing the value.

Definition at line 830 of file SafeDataReader.cs.