<?php
/**
* Inheritance: no
* Variants: no
Fields Summary:
- url [input]
- localizedfields [localizedfields]
-- e_name [input]
-- e_description [textarea]
-- e_slider_description [textarea]
-- location [input]
-- dateandtime [input]
-- meta_title [input]
-- meta_description [textarea]
-- webinarImage [image]
-- webinarLink [link]
-- webinarTitle [input]
- date_time [datetime]
- featured [booleanSelect]
- event_image [image]
- eventImageAr [image]
- e_images [imageGallery]
- videos [block]
-- video [video]
- similar_events [manyToManyObjectRelation]
- show [checkbox]
- detailListBlock [block]
-- localizedfields [localizedfields]
--- name [input]
*/
namespace Pimcore\Model\DataObject;
use Pimcore\Model\DataObject\Exception\InheritanceParentNotFoundException;
use Pimcore\Model\DataObject\PreGetValueHookInterface;
/**
* @method static \Pimcore\Model\DataObject\Events\Listing getList(array $config = [])
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByUrl($value, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByLocalizedfields($field, $value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByE_name($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByE_description($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByE_slider_description($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByLocation($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByDateandtime($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByMeta_title($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByMeta_description($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByWebinarImage($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByWebinarLink($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByWebinarTitle($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByDate_time($value, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByEvent_image($value, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByEventImageAr($value, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getBySimilar_events($value, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Events\Listing|\Pimcore\Model\DataObject\Events|null getByShow($value, $limit = 0, $offset = 0, $objectTypes = null)
*/
class Events extends Concrete
{
protected $o_classId = "events";
protected $o_className = "events";
protected $url;
protected $localizedfields;
protected $date_time;
protected $featured;
protected $event_image;
protected $eventImageAr;
protected $e_images;
protected $videos;
protected $similar_events;
protected $show;
protected $detailListBlock;
/**
* @param array $values
* @return \Pimcore\Model\DataObject\Events
*/
public static function create($values = array()) {
$object = new static();
$object->setValues($values);
return $object;
}
/**
* Get url - url
* @return string|null
*/
public function getUrl(): ?string
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("url");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->url;
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set url - url
* @param string|null $url
* @return \Pimcore\Model\DataObject\Events
*/
public function setUrl(?string $url)
{
$this->url = $url;
return $this;
}
/**
* Get localizedfields -
* @return \Pimcore\Model\DataObject\Localizedfield|null
*/
public function getLocalizedfields(): ?\Pimcore\Model\DataObject\Localizedfield
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("localizedfields");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->getClass()->getFieldDefinition("localizedfields")->preGetData($this);
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get e_name - Event Name
* @return string|null
*/
public function getE_name($language = null): ?string
{
$data = $this->getLocalizedfields()->getLocalizedValue("e_name", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("e_name");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get e_description - Event Description
* @return string|null
*/
public function getE_description($language = null): ?string
{
$data = $this->getLocalizedfields()->getLocalizedValue("e_description", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("e_description");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get e_slider_description - Event Slider Description
* @return string|null
*/
public function getE_slider_description($language = null): ?string
{
$data = $this->getLocalizedfields()->getLocalizedValue("e_slider_description", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("e_slider_description");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get location - Location
* @return string|null
*/
public function getLocation($language = null): ?string
{
$data = $this->getLocalizedfields()->getLocalizedValue("location", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("location");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get dateandtime - Date
* @return string|null
*/
public function getDateandtime($language = null): ?string
{
$data = $this->getLocalizedfields()->getLocalizedValue("dateandtime", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("dateandtime");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get meta_title - Meta Title
* @return string|null
*/
public function getMeta_title($language = null): ?string
{
$data = $this->getLocalizedfields()->getLocalizedValue("meta_title", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("meta_title");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get meta_description - Meta Description
* @return string|null
*/
public function getMeta_description($language = null): ?string
{
$data = $this->getLocalizedfields()->getLocalizedValue("meta_description", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("meta_description");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get webinarImage - Webinar Image
* @return \Pimcore\Model\Asset\Image|null
*/
public function getWebinarImage($language = null): ?\Pimcore\Model\Asset\Image
{
$data = $this->getLocalizedfields()->getLocalizedValue("webinarImage", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("webinarImage");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get webinarLink - Webinar Link
* @return \Pimcore\Model\DataObject\Data\Link|null
*/
public function getWebinarLink($language = null): ?\Pimcore\Model\DataObject\Data\Link
{
$data = $this->getLocalizedfields()->getLocalizedValue("webinarLink", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("webinarLink");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get webinarTitle - Webinar Title
* @return string|null
*/
public function getWebinarTitle($language = null): ?string
{
$data = $this->getLocalizedfields()->getLocalizedValue("webinarTitle", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("webinarTitle");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set localizedfields -
* @param \Pimcore\Model\DataObject\Localizedfield|null $localizedfields
* @return \Pimcore\Model\DataObject\Events
*/
public function setLocalizedfields(?\Pimcore\Model\DataObject\Localizedfield $localizedfields)
{
$hideUnpublished = \Pimcore\Model\DataObject\Concrete::getHideUnpublished();
\Pimcore\Model\DataObject\Concrete::setHideUnpublished(false);
$currentData = $this->getLocalizedfields();
\Pimcore\Model\DataObject\Concrete::setHideUnpublished($hideUnpublished);
$this->markFieldDirty("localizedfields", true);
$this->localizedfields = $localizedfields;
return $this;
}
/**
* Set e_name - Event Name
* @param string|null $e_name
* @return \Pimcore\Model\DataObject\Events
*/
public function setE_name (?string $e_name, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("e_name", $e_name, $language, !$isEqual);
return $this;
}
/**
* Set e_description - Event Description
* @param string|null $e_description
* @return \Pimcore\Model\DataObject\Events
*/
public function setE_description (?string $e_description, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("e_description", $e_description, $language, !$isEqual);
return $this;
}
/**
* Set e_slider_description - Event Slider Description
* @param string|null $e_slider_description
* @return \Pimcore\Model\DataObject\Events
*/
public function setE_slider_description (?string $e_slider_description, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("e_slider_description", $e_slider_description, $language, !$isEqual);
return $this;
}
/**
* Set location - Location
* @param string|null $location
* @return \Pimcore\Model\DataObject\Events
*/
public function setLocation (?string $location, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("location", $location, $language, !$isEqual);
return $this;
}
/**
* Set dateandtime - Date
* @param string|null $dateandtime
* @return \Pimcore\Model\DataObject\Events
*/
public function setDateandtime (?string $dateandtime, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("dateandtime", $dateandtime, $language, !$isEqual);
return $this;
}
/**
* Set meta_title - Meta Title
* @param string|null $meta_title
* @return \Pimcore\Model\DataObject\Events
*/
public function setMeta_title (?string $meta_title, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("meta_title", $meta_title, $language, !$isEqual);
return $this;
}
/**
* Set meta_description - Meta Description
* @param string|null $meta_description
* @return \Pimcore\Model\DataObject\Events
*/
public function setMeta_description (?string $meta_description, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("meta_description", $meta_description, $language, !$isEqual);
return $this;
}
/**
* Set webinarImage - Webinar Image
* @param \Pimcore\Model\Asset\Image|null $webinarImage
* @return \Pimcore\Model\DataObject\Events
*/
public function setWebinarImage (?\Pimcore\Model\Asset\Image $webinarImage, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("webinarImage", $webinarImage, $language, !$isEqual);
return $this;
}
/**
* Set webinarLink - Webinar Link
* @param \Pimcore\Model\DataObject\Data\Link|null $webinarLink
* @return \Pimcore\Model\DataObject\Events
*/
public function setWebinarLink (?\Pimcore\Model\DataObject\Data\Link $webinarLink, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("webinarLink", $webinarLink, $language, !$isEqual);
return $this;
}
/**
* Set webinarTitle - Webinar Title
* @param string|null $webinarTitle
* @return \Pimcore\Model\DataObject\Events
*/
public function setWebinarTitle (?string $webinarTitle, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("webinarTitle", $webinarTitle, $language, !$isEqual);
return $this;
}
/**
* Get date_time - Date and Time
* @return \Carbon\Carbon|null
*/
public function getDate_time(): ?\Carbon\Carbon
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("date_time");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->date_time;
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set date_time - Date and Time
* @param \Carbon\Carbon|null $date_time
* @return \Pimcore\Model\DataObject\Events
*/
public function setDate_time(?\Carbon\Carbon $date_time)
{
$this->date_time = $date_time;
return $this;
}
/**
* Get featured - Featured Event
* @return bool|null
*/
public function getFeatured(): ?bool
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("featured");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->featured;
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set featured - Featured Event
* @param bool|null $featured
* @return \Pimcore\Model\DataObject\Events
*/
public function setFeatured(?bool $featured)
{
$this->featured = $featured;
return $this;
}
/**
* Get event_image - Event Image
* @return \Pimcore\Model\Asset\Image|null
*/
public function getEvent_image(): ?\Pimcore\Model\Asset\Image
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("event_image");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->event_image;
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set event_image - Event Image
* @param \Pimcore\Model\Asset\Image|null $event_image
* @return \Pimcore\Model\DataObject\Events
*/
public function setEvent_image(?\Pimcore\Model\Asset\Image $event_image)
{
$this->event_image = $event_image;
return $this;
}
/**
* Get eventImageAr - Event Image Ar
* @return \Pimcore\Model\Asset\Image|null
*/
public function getEventImageAr(): ?\Pimcore\Model\Asset\Image
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("eventImageAr");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->eventImageAr;
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set eventImageAr - Event Image Ar
* @param \Pimcore\Model\Asset\Image|null $eventImageAr
* @return \Pimcore\Model\DataObject\Events
*/
public function setEventImageAr(?\Pimcore\Model\Asset\Image $eventImageAr)
{
$this->eventImageAr = $eventImageAr;
return $this;
}
/**
* Get e_images - Event Images
* @return \Pimcore\Model\DataObject\Data\ImageGallery|null
*/
public function getE_images(): ?\Pimcore\Model\DataObject\Data\ImageGallery
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("e_images");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->e_images;
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set e_images - Event Images
* @param \Pimcore\Model\DataObject\Data\ImageGallery|null $e_images
* @return \Pimcore\Model\DataObject\Events
*/
public function setE_images(?\Pimcore\Model\DataObject\Data\ImageGallery $e_images)
{
$this->e_images = $e_images;
return $this;
}
/**
* Get videos - videos
* @return \Pimcore\Model\DataObject\Data\BlockElement[][]
*/
public function getVideos(): ?array
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("videos");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->getClass()->getFieldDefinition("videos")->preGetData($this);
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set videos - videos
* @param \Pimcore\Model\DataObject\Data\BlockElement[][] $videos
* @return \Pimcore\Model\DataObject\Events
*/
public function setVideos(?array $videos)
{
/** @var \Pimcore\Model\DataObject\ClassDefinition\Data\Block $fd */
$fd = $this->getClass()->getFieldDefinition("videos");
$this->videos = $fd->preSetData($this, $videos);
return $this;
}
/**
* Get similar_events - Similar Events
* @return \Pimcore\Model\DataObject\Events[]
*/
public function getSimilar_events(): array
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("similar_events");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->getClass()->getFieldDefinition("similar_events")->preGetData($this);
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set similar_events - Similar Events
* @param \Pimcore\Model\DataObject\Events[] $similar_events
* @return \Pimcore\Model\DataObject\Events
*/
public function setSimilar_events(?array $similar_events)
{
/** @var \Pimcore\Model\DataObject\ClassDefinition\Data\ManyToManyObjectRelation $fd */
$fd = $this->getClass()->getFieldDefinition("similar_events");
$hideUnpublished = \Pimcore\Model\DataObject\Concrete::getHideUnpublished();
\Pimcore\Model\DataObject\Concrete::setHideUnpublished(false);
$currentData = $this->getSimilar_events();
\Pimcore\Model\DataObject\Concrete::setHideUnpublished($hideUnpublished);
$isEqual = $fd->isEqual($currentData, $similar_events);
if (!$isEqual) {
$this->markFieldDirty("similar_events", true);
}
$this->similar_events = $fd->preSetData($this, $similar_events);
return $this;
}
/**
* Get show - Show
* @return bool|null
*/
public function getShow(): ?bool
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("show");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->show;
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set show - Show
* @param bool|null $show
* @return \Pimcore\Model\DataObject\Events
*/
public function setShow(?bool $show)
{
$this->show = $show;
return $this;
}
/**
* Get detailListBlock - Detail List Block
* @return \Pimcore\Model\DataObject\Data\BlockElement[][]
*/
public function getDetailListBlock(): ?array
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("detailListBlock");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->getClass()->getFieldDefinition("detailListBlock")->preGetData($this);
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set detailListBlock - Detail List Block
* @param \Pimcore\Model\DataObject\Data\BlockElement[][] $detailListBlock
* @return \Pimcore\Model\DataObject\Events
*/
public function setDetailListBlock(?array $detailListBlock)
{
/** @var \Pimcore\Model\DataObject\ClassDefinition\Data\Block $fd */
$fd = $this->getClass()->getFieldDefinition("detailListBlock");
$this->detailListBlock = $fd->preSetData($this, $detailListBlock);
return $this;
}
}