public virtual void Dispose() { try { using (Profiler.Measure("WorkflowRunContext.Dispose")) { // deal with deferred stuff if (TriggerDepth == 0 || _parentContext == null || HandleDeferred) { HandleDeferredStuff(); } // Pop _currentContext = _parentContext; } } finally { if (_profiler != null) { _profiler.Dispose(); } } }
public WorkflowRunContext(WorkflowRunContext other, bool handleDeferred) { HandleDeferred = handleDeferred; _profiler = Profiler.Measure("WorkflowRunContext", false); if (other != null) { RunTriggersInCurrentThread = other.RunTriggersInCurrentThread; DisableTriggers = other.DisableTriggers; TriggerDepth = other.TriggerDepth; _parentContext = _currentContext; _currentContext = this; } }
public WorkflowRunContext(WorkflowRunContext other) : this(other, false) { }