prepareObject() protected method

Prepare an object copy for toObject()
protected prepareObject ( stdClass $object ) : stdClass
$object stdClass Object representation of the entity
return stdClass
Example #1
0
 /**
  * {@inheritdoc}
  */
 protected function prepareObject($object)
 {
     $object = parent::prepareObject($object);
     $object->name = $this->getDisplayName();
     $object->username = $this->username;
     $object->language = $this->language;
     unset($object->read_access);
     return $object;
 }
Example #2
0
 /**
  * {@inheritdoc}
  */
 protected function prepareObject($object)
 {
     $object = parent::prepareObject($object);
     $object->title = $this->getDisplayName();
     $object->description = $this->description;
     $object->tags = $this->tags ? $this->tags : array();
     return $object;
 }
Example #3
0
 /**
  * {@inheritdoc}
  */
 protected function prepareObject($object)
 {
     $object = parent::prepareObject($object);
     $object->name = $this->getDisplayName();
     $object->description = $this->description;
     unset($object->read_access);
     return $object;
 }