public function toArray($type = BasePeer::TYPE_FIELDNAME) { $data = parent::toArray($type); $bouUid = $this->bound->getBouUid(); if (empty($bouUid)) { $bound = BpmnBound::findByElement('Gateway', $this->getGatUid()); if (is_object($bound)) { $this->bound = $bound; } } $data = array_merge($data, $this->bound->toArray($type)); return $data; }