Exemplo n.º 1
0
 public function addStep($name, $options = array())
 {
     $stepType = !empty($options['type']) ? $options['type'] : 'Step';
     $step = AbstractStep::createStep($stepType, $name, $options);
     //Get the steps that follows this step which are automatically generated by this step
     $precedingSteps = $step->getPrecedingSteps();
     $this->appendSteps($precedingSteps);
     $this->appendStep($step);
     //Get the steps that follows this step which are automatically generated by this step
     $followSteps = $step->getFollowingSteps();
     $this->appendSteps($followSteps);
     return $step;
 }