/// <summary>
 /// Executes the user code to retrieve the task.
 /// </summary>
 /// <param name="context"></param>
 /// <returns></returns>
 Task ExecuteInternalAsync(AsyncCodeActivityContext context)
 {
     // search local, for an executor scope, or default to the extension
     return(ExecuteAsync(context,
                         Executor ??
                         context.GetProperty <AsyncTaskExecutorHandle>()?.Executor ??
                         context.GetExtension <AsyncTaskExtension>().Executor));
 }
Ejemplo n.º 2
0
        void GetTransactionFromContext(AsyncCodeActivityContext context)
        {
            RuntimeTransactionHandle transactionHandle = context.GetProperty <RuntimeTransactionHandle>();

            if (transactionHandle != null)
            {
                this.Transaction = transactionHandle.GetCurrentTransaction(context);
            }
        }