Exemplo n.º 1
0
        private void ScheduleNextActivities(WorkflowExecutionContext workflowContext, SourceEndpoint endpoint)
        {
            var completedActivity = workflowContext.CurrentActivity;
            var connections       = workflowContext.Workflow.Connections.Where(x => x.Source.Activity == completedActivity && (x.Source.Outcome ?? OutcomeNames.Done) == endpoint.Outcome);
            var activities        = connections.Select(x => x.Target.Activity);

            workflowContext.ScheduleActivities(activities);
        }
Exemplo n.º 2
0
        private void ScheduleNextActivities(WorkflowExecutionContext workflowContext, SourceEndpoint endpoint)
        {
            var completedActivity = workflowContext.CurrentActivity;
            var connections       = workflowContext.Workflow.Connections.Where(x => x.Source.Activity == completedActivity &&
                                                                               (x.Source.Outcome ?? OutcomeNames.Done).Equals(endpoint.Outcome, StringComparison.OrdinalIgnoreCase));
            var activities = connections.Select(x => x.Target.Activity);

            workflowContext.ScheduleActivities(activities);
        }