Exemplo n.º 1
0
 /// <summary>
 ///
 /// </summary>
 /// <typeparam name="T"></typeparam>
 /// <param name="sprocName"></param>
 /// <param name="parameters"></param>
 /// <returns></returns>
 public IEnumerable <T> WorkWithMultipleResultSetSproc <T>(string sprocName, params DbParameter[] parameters)
 {
     if (efr == null || efr.CommandUsed.CommandText != sprocName)
     {
         return(this.ExecuteSproc <T>(sprocName, parameters));
     }
     else
     {
         return(efr.GetNextResultFromDataReader <T>((IObjectContextAdapter)this));
     }
 }
Exemplo n.º 2
0
 /// <summary>
 ///
 /// </summary>
 /// <typeparam name="T"></typeparam>
 /// <param name="sprocName"></param>
 /// <param name="parameters"></param>
 /// <returns></returns>
 public IEnumerable <T> ExecuteSproc <T>(string sprocName, params DbParameter[] parameters)
 {
     this.efr = new EFResults(this.SetUpCommandObjectForSproc(sprocName, parameters), true);
     return(efr.GetNextResultFromDataReader <T>((IObjectContextAdapter)this));
 }