Ejemplo n.º 1
0
 /// <summary>
 /// 把结果集流转换成数据实体序列(延迟)
 /// </summary>
 /// <typeparam name="T">数据实体类型</typeparam>
 /// <param name="reader">结果集流</param>
 /// <returns>数据实体序列(延迟)</returns>
 public static IEnumerable <T> DataReaderToListLazy <T>(this IDataReader reader)
     where T : class, new()
 {
     if (reader == null)
     {
         throw new ArgumentNullException("reader");
     }
     return(EntityConverter <T> .DataReaderToListDelay(reader));
 }