/// <summary>
        /// 创建ActivitySchedule
        /// </summary>
        /// <param name="processModel">流程模型</param>
        /// <param name="splitJoinType">分支合并类型</param>
        /// <returns>下一步调度类</returns>
        internal static NextActivityScheduleBase CreateActivitySchedule(IProcessModel processModel,
                                                                        GatewaySplitJoinTypeEnum splitJoinType)
        {
            NextActivityScheduleBase activitySchedule = null;

            if (splitJoinType == GatewaySplitJoinTypeEnum.Split)
            {
                activitySchedule = new NextActivityScheduleSplit(processModel);
            }
            else if (splitJoinType == GatewaySplitJoinTypeEnum.Join)
            {
                activitySchedule = new NextActivityScheduleJoin(processModel);
            }
            else
            {
                throw new Exception("未知的splitJoinType!");
            }
            return(activitySchedule);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 创建ActivitySchedule
        /// </summary>
        /// <param name="processModel">流程模型</param>
        /// <param name="splitJoinType">分支合并类型</param>
        /// <returns>下一步调度类</returns>
        internal static NextActivityScheduleBase CreateActivitySchedule(IProcessModel processModel,
                                                                        GatewaySplitJoinTypeEnum splitJoinType)
        {
            NextActivityScheduleBase activitySchedule = null;

            if (splitJoinType == GatewaySplitJoinTypeEnum.Split)
            {
                activitySchedule = new NextActivityScheduleSplit(processModel);
            }
            else if (splitJoinType == GatewaySplitJoinTypeEnum.Join)
            {
                activitySchedule = new NextActivityScheduleJoin(processModel);
            }
            else
            {
                //未知的splitJoinType
                throw new Exception(LocalizeHelper.GetEngineMessage("nextactivityschedulefactory.unknownnodetype"));
            }
            return(activitySchedule);
        }