/** * (non-PHPdoc) * @see \PartKeepr\Util\Deserializable::deserialize() */ public function deserialize(array $parameters) { foreach ($parameters as $key => $value) { switch ($key) { case "name": $this->setName($value); break; case "comment": $this->setComment($value); break; case "objectType": $this->setObjectType($value); break; case "exportRenderer": $this->setExportRenderer($value); break; case "pageLayout": if ($value === 0) { $this->setPageLayout(null); } else { try { $this->setPageLayout(PageBasicLayout::loadById($value)); } catch (\Exception $e) { $this->setPageLayout(null); } } break; case "rendererConfiguration": $this->setRendererConfiguration($value); break; } } }