мой метод:
public TableFilled<TKey, TRow> getTera()
{
Func<TablesFilled<TKey,TRow>> _getTera=new Func<TablesFilled<TKey,TRow>>(
()=>{return (TablesFilled<TKey,TRow>) chGetTera();});
//Above does not compile says: Cannot convert type
//'AcapsVerify.FunctionalTables.TableFilled<TKey,TRow>' to
//'AcapsVerify.FunctionalTables.TablesFilled<TKey,TRow>'
// the line below has the same blue underline error.
return _getTera.TimeAndReport("Finished Teradata",OutputIfListener);
// this works fine
return chGetTera;
}
Статический метод, который он вызывает
public static T TimeAndReport<T>(this Func<T> timedFunc, String reportLead, Action<String> reporterAction)
{
T result;
var s = new System.Diagnostics.Stopwatch();
s.Start();
result = timedFunc();
s.Stop();
reporterAction(reportLead + " in " + s.WholePartOnly());
return result;
}
возвращаем определение класса:
public class TableFilled<TKey,TRow> where TRow: STeraRow<TKey>