public function onAfterTransition(TransitionEvent $e)
 {
     /** @var DNDeployment $deployment */
     $deployment = $e->getStateMachine()->getObject();
     $deployment->log()->write(sprintf('State transitioned from "%s" to "%s"', $e->getInitialState()->getName(), $e->getTransition()->getState()));
 }
 /**
  * {@inheritdoc}
  */
 public function isSatisfiedBy(TransitionEvent $event)
 {
     return $event->getStateMachine() === $this->stateMachine && $this->supportsClause('from', $event->getInitialState()->getName()) && $this->supportsClause('to', $event->getTransition()->getState()) && $this->supportsClause('on', $event->getTransition()->getName());
 }
 public function onPostTransition(TransitionEvent $event)
 {
     $object = $event->getStateMachine()->getObject();
     $this->callCallback($object, 'post', $event->getTransition()->getName());
 }