// Token: 0x06001657 RID: 5719 RVA: 0x00027392 File Offset: 0x00026392 protected virtual void OnFaulting(Exception ex, WorkflowElement sender) { if (this.faultCallback != null) { this.faultCallback(this, ex, sender); } }
// Token: 0x06001658 RID: 5720 RVA: 0x000273AA File Offset: 0x000263AA protected virtual void OnFaulted(Exception ex, WorkflowElement sender) { if (this.Faulted != null) { this.Faulted(this, ex, sender); } }
// Token: 0x06001656 RID: 5718 RVA: 0x0002737B File Offset: 0x0002637B protected virtual void OnCompletion(WorkflowElement sender) { if (this.completionCallback != null) { this.completionCallback(this, sender); } }
// Token: 0x06001648 RID: 5704 RVA: 0x0002707B File Offset: 0x0002607B private void ThrowFault(Exception ex, WorkflowElement element) { this.Status = ActivityExecutionStatus.Faulting; this.OnFaulting(ex, element); if (this.IsFaulting) { this.Fault(); this.OnFaulted(ex, element); } }
// Token: 0x060016BE RID: 5822 RVA: 0x00027CD8 File Offset: 0x00026CD8 public static WorkflowRunner Construct(string workflow, InternalCollection collection) { WorkflowElement workflowElement = Activator.CreateInstance <WorkflowElement>(workflow); if (workflowElement != null) { ICollectionOwner collectionOwner = workflowElement as ICollectionOwner; if (collectionOwner != null) { collectionOwner.Bind(collection); } return(new WorkflowRunner(workflowElement)); } return(null); }
// Token: 0x0600164F RID: 5711 RVA: 0x00027158 File Offset: 0x00026158 public void ScheduleActivity(WorkflowElement element, CompletionCallback completionCallback, FaultCallback faultCallback) { if (element != null) { ActivityExecutionContext activityExecutionContext = new ActivityExecutionContext(this.instance, element); this.completionCallback = completionCallback; this.faultCallback = faultCallback; ActivityExecutionContext activityExecutionContext2 = activityExecutionContext; activityExecutionContext2.StatusChanged = (StatusChangedHandler)Delegate.Combine(activityExecutionContext2.StatusChanged, new StatusChangedHandler(this.OnDependencyStatusChanged)); ActivityExecutionContext activityExecutionContext3 = activityExecutionContext; activityExecutionContext3.Faulted = (FaultCallback)Delegate.Combine(activityExecutionContext3.Faulted, new FaultCallback(this.OnDependencyFaulted)); if (!this.children.Contains(element)) { this.children.Add(element); } this.scheduled.Add(activityExecutionContext); this.instance.ScheduleItem(activityExecutionContext); } }
// Token: 0x060016BD RID: 5821 RVA: 0x00027CC4 File Offset: 0x00026CC4 internal WorkflowRunner(WorkflowElement element) { this.instance = WorkflowInstance.Create(element); }
// Token: 0x0600164E RID: 5710 RVA: 0x0002714D File Offset: 0x0002614D public void ScheduleActivity(WorkflowElement element, CompletionCallback completionCallback) { this.ScheduleActivity(element, completionCallback, null); }
// Token: 0x0600164D RID: 5709 RVA: 0x00027143 File Offset: 0x00026143 public void ScheduleActivity(WorkflowElement element) { this.ScheduleActivity(element, null); }
// Token: 0x06001653 RID: 5715 RVA: 0x00027333 File Offset: 0x00026333 private void OnDependencyFaulted(ActivityExecutionContext context, Exception ex, WorkflowElement sender) { this.ThrowFault(ex, sender); }
// Token: 0x06001645 RID: 5701 RVA: 0x00026F9C File Offset: 0x00025F9C public ActivityExecutionContext(WorkflowInstance instance, WorkflowElement element) { this.instance = instance; this.element = element; this.element.OnGetChildren(this.children); }
// Token: 0x060016AB RID: 5803 RVA: 0x000279E1 File Offset: 0x000269E1 private WorkflowInstance(WorkflowElement element) { this.scheduled = new Queue <ActivityExecutionContext>(); this.element = element; }
// Token: 0x060016B3 RID: 5811 RVA: 0x00027BC2 File Offset: 0x00026BC2 protected void OnFaulted(ActivityExecutionContext context, Exception ex, WorkflowElement sender) { Console.WriteLine(string.Format("Workflow Instance Faulted: {0}", this.element)); }
// Token: 0x060016AD RID: 5805 RVA: 0x00027A38 File Offset: 0x00026A38 internal static WorkflowInstance Create(WorkflowElement element) { return(new WorkflowInstance(element)); }