Ejemplo n.º 1
0
 /// <summary>
 /// Invokes the specified monitor with the given event.
 /// </summary>
 /// <typeparam name="T">Type of the monitor</typeparam>
 /// <param name="e">Event</param>
 /// <param name="payload">Optional payload</param>
 public static void InvokeMonitor <T>(Event e, params Object[] payload)
 {
     // If the event is null then report an error and exit.
     PSharpRuntime.Assert(e != null, "Cannot send a null event.");
     e.AssignPayload(payload);
     PSharpRuntime.Monitor <T>(e);
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Invokes the specified monitor with the given event.
 /// </summary>
 /// <typeparam name="T">Type of the monitor</typeparam>
 /// <param name="e">Event</param>
 void IDispatcher.Monitor <T>(Event e)
 {
     PSharpRuntime.Monitor <T>(e);
 }