Ejemplo n.º 1
0
 public static Task FireEventAsync(this MtApiQuoteHandler evenHandler, object sender, string symbol, double bid, double ask)
 {
     return(Task.Factory.StartNew(() =>
     {
         evenHandler?.Invoke(sender, symbol, bid, ask);
     }));
 }
Ejemplo n.º 2
0
 public static async void FireEvent(this MtApiQuoteHandler evenHandler, object sender, string symbol, double bid, double ask)
 {
     if (evenHandler != null)
     {
         await Task.Factory.StartNew(() =>
         {
             evenHandler(sender, symbol, bid, ask);
         });
     }
 }