예제 #1
0
파일: Drawer.php 프로젝트: spryker/Oms
 /**
  * @param \Spryker\Zed\Oms\Business\Process\StateInterface $state
  *
  * @return bool
  */
 protected function hasOnlySelfReferences(StateInterface $state)
 {
     $hasOnlySelfReferences = true;
     $transitions = $state->getOutgoingTransitions();
     foreach ($transitions as $transition) {
         if ($transition->getTarget()->getName() !== $state->getName()) {
             $hasOnlySelfReferences = false;
             break;
         }
     }
     return $hasOnlySelfReferences;
 }
예제 #2
0
파일: Process.php 프로젝트: spryker/Oms
 /**
  * @param \Spryker\Zed\Oms\Business\Process\StateInterface $state
  *
  * @return void
  */
 public function addState(StateInterface $state)
 {
     $this->states[$state->getName()] = $state;
 }