src/Azos/Time/Event.cs
/// <summary>
/// Calls event regardless of any constraints.
/// Invokes a handler right away if syncInvoke is true or BodyAsyncModel is Sync,
/// otherwise queues the task on a thread pool either as a regular or long-running task depending on BodyAsyncModel
/// </summary>
Calls event regardless of any constraints.
Invokes a handler right away if syncInvoke is true or BodyAsyncModel is Sync,
otherwise queues the task on a thread pool either as a regular or long-running task depending on BodyAsyncModel
Calls event regardless of any constraints . Invokes a handler right away if syncInvoke is true or BodyAsyncModel is Sync otherwise queues the task on a thread pool either as a regular or long - running task depending on BodyAsyncModel
public void Fire(bool syncInvoke = false)
      {
        if (Disposed) return;
        if (syncInvoke || BodyAsyncModel==EventBodyAsyncModel.Sync)
         fireBody();
        else
        {
          if (BodyAsyncModel==EventBodyAsyncModel.LongRunningAsyncTask)
            Task.Factory.StartNew( fireBody, TaskCreationOptions.LongRunning );
          else
            Task.Factory.StartNew( fireBody );
        }
      }
public void Fire ( bool syncInvoke = false ) { if ( Disposed ) return ; if ( syncInvoke || BodyAsyncModel == EventBodyAsyncModel . Sync ) fireBody ( ) ; else { if ( BodyAsyncModel == EventBodyAsyncModel . LongRunningAsyncTask ) Task . Factory . StartNew ( fireBody , TaskCreationOptions . LongRunning ) ; else Task . Factory . StartNew ( fireBody ) ; } }
Calls event regardless of any constraints.
Calls event regardless of any constraints .
syncInvoke
bool