コード例 #1
0
 protected T CheckStepIs <T>(ActionStep t)
     where T : ActionStep
 {
     if (!typeof(T).IsAssignableFrom(t.GetType()))
     {
         throw new DomainException("Step submitted is of the incorrect type for the current StepNumber of the Activity");
     }
     return(t as T);
 }
コード例 #2
0
 protected void CheckStepNumberAndChangeIfValid(ActionStep fromStep)
 {
     if (fromStep.StepNumber > StepNumber)
     {
         throw new DomainException("Invalid step being submitted");
     }
     if (fromStep.StepNumber < StepNumber)
     {
         StepNumber = fromStep.StepNumber;
     }
 }
コード例 #3
0
 public abstract ActionStep ProcessSubmittedStep(ActionStep fromStep);