original_string: public function setStatus(Result\ResultStatus $status)
      {
          if (Result\ResultStatus::UNPROCESSED !== $status->getValue()) {
              $this->transacted = true;
              $this->dateTransacted = new DateTime();
          }
  
          if (!$this->transaction->isParent()
              && Result\ResultStatus::ERROR !== $status->getValue()
              && Result\ResultStatus::UNPROCESSED !== $status->getValue())  {
              $this->transaction->getParent()->setStatus($status);
          }
  
          $this->transaction->setStatus($status);
          $this->status = $status;
      }
code: public function setStatus(Result\ResultStatus $status)
      {
          if (Result\ResultStatus::UNPROCESSED !== $status->getValue()) {
              $this->transacted = true;
              $this->dateTransacted = new DateTime();
          }
  
          if (!$this->transaction->isParent()
              && Result\ResultStatus::ERROR !== $status->getValue()
              && Result\ResultStatus::UNPROCESSED !== $status->getValue())  {
              $this->transaction->getParent()->setStatus($status);
          }
  
          $this->transaction->setStatus($status);
          $this->status = $status;
      }
code_tokens: public function setStatus ( Result \ ResultStatus $ status ) { if ( Result \ ResultStatus :: UNPROCESSED !== $ status -> getValue ( ) ) { $ this -> transacted = true ; $ this -> dateTransacted = new DateTime ( ) ; } if ( ! $ this -> transaction -> isParent ( ) && Result \ ResultStatus :: ERROR !== $ status -> getValue ( ) && Result \ ResultStatus :: UNPROCESSED !== $ status -> getValue ( ) ) { $ this -> transaction -> getParent ( ) -> setStatus ( $ status ) ; } $ this -> transaction -> setStatus ( $ status ) ; $ this -> status = $ status ; }
docstring: Sets the result type
  
  @param \Orkestra\Transactor\Entity\Result\ResultStatus $status
docstring_tokens: Sets the result type