Exemplo n.º 1
0
 public static void AddSingleResultInfoFunction(this IInfoProvider infoProvider, string name, SingleResultInfoFunction func)
 {
     infoProvider.Functions.Add("info_" + name, (settings) =>
     {
         var ir = func(settings as InfoSettings);
         var ifr = new InfoFunctionResult();
         ifr.InfoResults.Add("default", ir);
         ifr.RanSuccessfully = ir.RanSuccessfully;
         ifr.FunctionException = ir.ExecutionException;
         ifr.Message = ir.Message;
         return ifr;
     });
 }
Exemplo n.º 2
0
 public static void AddSingleResultInfoFunction(this IInfoProvider infoProvider, SingleResultInfoFunction func)
 {
     infoProvider.AddSingleResultInfoFunction("default", func);
 }