示例#1
0
        private Activity GetStartActivity(WorkflowExecutionContext context)
        {
            if (context.Restoring)
            {
                return(Activities[context.GetActivityNameToRestore()]);
            }
            if (StartActivity == null)
            {
                return(Activities.Values.First());
            }
            var startActivityFullName = WorkflowSchemeParser.CreateFullActivityName(StartActivity, Name);

            if (!Activities.ContainsKey(startActivityFullName))
            {
                throw new ActivityExecutionException(
                          "Начальное действие не найдено: " + startActivityFullName, this, context);
            }
            return(Activities[startActivityFullName]);
        }
示例#2
0
 public Activity GetChildActivity(string localChildActivityName)
 {
     return(Activities[WorkflowSchemeParser.CreateFullActivityName(localChildActivityName, this)]);
 }