<?php
/**
* Inheritance: no
* Variants: no
*
* Fields Summary:
* - bild [image]
* - bild_saison_winter [image]
* - localizedfields [localizedfields]
* -- title [textarea]
* -- headline_small [textarea]
* -- link [link]
* -- button_text [textarea]
*/
namespace Pimcore\Model\DataObject;
use Pimcore\Model\DataObject\Exception\InheritanceParentNotFoundException;
use Pimcore\Model\DataObject\PreGetValueHookInterface;
/**
* @method static \Pimcore\Model\DataObject\Teaserquerformat\Listing getList(array $config = [])
* @method static \Pimcore\Model\DataObject\Teaserquerformat\Listing|\Pimcore\Model\DataObject\Teaserquerformat|null getByBild($value, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Teaserquerformat\Listing|\Pimcore\Model\DataObject\Teaserquerformat|null getByBild_saison_winter($value, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Teaserquerformat\Listing|\Pimcore\Model\DataObject\Teaserquerformat|null getByLocalizedfields($field, $value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Teaserquerformat\Listing|\Pimcore\Model\DataObject\Teaserquerformat|null getByTitle($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Teaserquerformat\Listing|\Pimcore\Model\DataObject\Teaserquerformat|null getByHeadline_small($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Teaserquerformat\Listing|\Pimcore\Model\DataObject\Teaserquerformat|null getByLink($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
* @method static \Pimcore\Model\DataObject\Teaserquerformat\Listing|\Pimcore\Model\DataObject\Teaserquerformat|null getByButton_text($value, $locale = null, $limit = 0, $offset = 0, $objectTypes = null)
*/
class Teaserquerformat extends Concrete
{
protected $o_classId = "19";
protected $o_className = "teaserquerformat";
protected $bild;
protected $bild_saison_winter;
protected $localizedfields;
/**
* @param array $values
* @return \Pimcore\Model\DataObject\Teaserquerformat
*/
public static function create($values = array()) {
$object = new static();
$object->setValues($values);
return $object;
}
/**
* Get bild - Bild (Sommer)
* @return \Pimcore\Model\Asset\Image|null
*/
public function getBild()
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("bild");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->bild;
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set bild - Bild (Sommer)
* @param \Pimcore\Model\Asset\Image|null $bild
* @return \Pimcore\Model\DataObject\Teaserquerformat
*/
public function setBild($bild)
{
$this->bild = $bild;
return $this;
}
/**
* Get bild_saison_winter - Bild (Winter)
* @return \Pimcore\Model\Asset\Image|null
*/
public function getBild_saison_winter()
{
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("bild_saison_winter");
if ($preValue !== null) {
return $preValue;
}
}
$data = $this->bild_saison_winter;
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Set bild_saison_winter - Bild (Winter)
* @param \Pimcore\Model\Asset\Image|null $bild_saison_winter
* @return \Pimcore\Model\DataObject\Teaserquerformat
*/
public function setBild_saison_winter($bild_saison_winter)
{
$this->bild_saison_winter = $bild_saison_winter;
return $this;
}
/**
* Get localizedfields -
* @return \Pimcore\Model\DataObject\Localizedfield|null
*/
public function getLocalizedfields()
{
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 title - grosse Headline
* @return string|null
*/
public function getTitle($language = null)
{
$data = $this->getLocalizedfields()->getLocalizedValue("title", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("title");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get headline_small - schmale (sub) Headline
* @return string|null
*/
public function getHeadline_small($language = null)
{
$data = $this->getLocalizedfields()->getLocalizedValue("headline_small", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("headline_small");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get link - Link (Optional)
* @return \Pimcore\Model\DataObject\Data\Link|null
*/
public function getLink($language = null)
{
$data = $this->getLocalizedfields()->getLocalizedValue("link", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("link");
if ($preValue !== null) {
return $preValue;
}
}
if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
return $data->getPlain();
}
return $data;
}
/**
* Get button_text - Button Text
* @return string|null
*/
public function getButton_text($language = null)
{
$data = $this->getLocalizedfields()->getLocalizedValue("button_text", $language);
if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
$preValue = $this->preGetValue("button_text");
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\Teaserquerformat
*/
public function setLocalizedfields($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 title - grosse Headline
* @param string|null $title
* @return \Pimcore\Model\DataObject\Teaserquerformat
*/
public function setTitle ($title, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("title", $title, $language, !$isEqual);
return $this;
}
/**
* Set headline_small - schmale (sub) Headline
* @param string|null $headline_small
* @return \Pimcore\Model\DataObject\Teaserquerformat
*/
public function setHeadline_small ($headline_small, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("headline_small", $headline_small, $language, !$isEqual);
return $this;
}
/**
* Set link - Link (Optional)
* @param \Pimcore\Model\DataObject\Data\Link|null $link
* @return \Pimcore\Model\DataObject\Teaserquerformat
*/
public function setLink ($link, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("link", $link, $language, !$isEqual);
return $this;
}
/**
* Set button_text - Button Text
* @param string|null $button_text
* @return \Pimcore\Model\DataObject\Teaserquerformat
*/
public function setButton_text ($button_text, $language = null)
{
$isEqual = false;
$this->getLocalizedfields()->setLocalizedValue("button_text", $button_text, $language, !$isEqual);
return $this;
}
}