DataContext::Translate Method
.NET Framework (current version)
Converts an existing IDataReader to objects.
Assembly: System.Data.Linq (in System.Data.Linq.dll)
| Name | Description | |
|---|---|---|
![]() | Translate(DbDataReader^) | Converts an existing DbDataReader to objects. |
![]() | Translate(Type^, DbDataReader^) | Converts an existing DbDataReader to objects. |
![]() | Translate<TResult>(DbDataReader^) | Converts an existing DbDataReader to objects. |
Each row in the IDataReader is converted to an object in the IEnumerable<T>.
public IEnumerable<T> Translate<T>(IDataReader reader) {}
Description: This method is used to convert an existing DbDataReader to objects. Each row in the DbDataReader is converted to an object in the IEnumerable<T>.
Generic parameters:
T: See ExecuteQuery<TResult>.
Parameters:
Query: See the description for command under ExecuteCommand.
Parameters: See the description for parameters under ExecuteCommand.
Return type:
IEnumerable<T>: collection of objects returned by the conversion.
Show:
