/**
  * @param object $object
  * @return $this
  * @throws UnexpectedValueException
  */
 public function fromObject($object)
 {
     parent::fromObject($object);
     if (property_exists($object, 'creationOutput')) {
         if (!is_object($object->creationOutput)) {
             throw new UnexpectedValueException('value \'' . print_r($object->creationOutput, true) . '\' is not an object');
         }
         $value = new PaymentCreationOutput();
         $this->creationOutput = $value->fromObject($object->creationOutput);
     }
     if (property_exists($object, 'merchantAction')) {
         if (!is_object($object->merchantAction)) {
             throw new UnexpectedValueException('value \'' . print_r($object->merchantAction, true) . '\' is not an object');
         }
         $value = new MerchantAction();
         $this->merchantAction = $value->fromObject($object->merchantAction);
     }
     if (property_exists($object, 'payment')) {
         if (!is_object($object->payment)) {
             throw new UnexpectedValueException('value \'' . print_r($object->payment, true) . '\' is not an object');
         }
         $value = new Payment();
         $this->payment = $value->fromObject($object->payment);
     }
     return $this;
 }
 /**
  * @param object $object
  * @return $this
  * @throws UnexpectedValueException
  */
 public function fromObject($object)
 {
     parent::fromObject($object);
     if (property_exists($object, 'displayedData')) {
         if (!is_object($object->displayedData)) {
             throw new UnexpectedValueException('value \'' . print_r($object->displayedData, true) . '\' is not an object');
         }
         $value = new DisplayedData();
         $this->displayedData = $value->fromObject($object->displayedData);
     }
     if (property_exists($object, 'payment')) {
         if (!is_object($object->payment)) {
             throw new UnexpectedValueException('value \'' . print_r($object->payment, true) . '\' is not an object');
         }
         $value = new Payment();
         $this->payment = $value->fromObject($object->payment);
     }
     if (property_exists($object, 'paymentCreationReferences')) {
         if (!is_object($object->paymentCreationReferences)) {
             throw new UnexpectedValueException('value \'' . print_r($object->paymentCreationReferences, true) . '\' is not an object');
         }
         $value = new PaymentCreationReferences();
         $this->paymentCreationReferences = $value->fromObject($object->paymentCreationReferences);
     }
     if (property_exists($object, 'paymentStatusCategory')) {
         $this->paymentStatusCategory = $object->paymentStatusCategory;
     }
     if (property_exists($object, 'tokens')) {
         $this->tokens = $object->tokens;
     }
     return $this;
 }
 /**
  * @param object $object
  * @return $this
  * @throws UnexpectedValueException
  */
 public function fromObject($object)
 {
     parent::fromObject($object);
     if (property_exists($object, 'payment')) {
         if (!is_object($object->payment)) {
             throw new UnexpectedValueException('value \'' . print_r($object->payment, true) . '\' is not an object');
         }
         $value = new Payment();
         $this->payment = $value->fromObject($object->payment);
     }
     return $this;
 }
 /**
  * @param object $object
  * @return $this
  * @throws UnexpectedValueException
  */
 public function fromObject($object)
 {
     parent::fromObject($object);
     return $this;
 }