var/classes/DataObject/Galerie.php line 22

Open in your IDE?
  1. <?php
  2. /**
  3.  * Inheritance: no
  4.  * Variants: no
  5.  *
  6.  * Fields Summary:
  7.  * - title [input]
  8.  * - images [imageGallery]
  9.  */
  10. namespace Pimcore\Model\DataObject;
  11. use Pimcore\Model\DataObject\Exception\InheritanceParentNotFoundException;
  12. use Pimcore\Model\DataObject\PreGetValueHookInterface;
  13. /**
  14. * @method static \Pimcore\Model\DataObject\Galerie\Listing getList(array $config = [])
  15. * @method static \Pimcore\Model\DataObject\Galerie\Listing|\Pimcore\Model\DataObject\Galerie|null getByTitle($value, $limit = 0, $offset = 0, $objectTypes = null)
  16. */
  17. class Galerie extends Concrete
  18. {
  19. protected $o_classId "4";
  20. protected $o_className "Galerie";
  21. protected $title;
  22. protected $images;
  23. /**
  24. * @param array $values
  25. * @return \Pimcore\Model\DataObject\Galerie
  26. */
  27. public static function create($values = array()) {
  28.     $object = new static();
  29.     $object->setValues($values);
  30.     return $object;
  31. }
  32. /**
  33. * Get title - Titel
  34. * @return string|null
  35. */
  36. public function getTitle(): ?string
  37. {
  38.     if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
  39.         $preValue $this->preGetValue("title");
  40.         if ($preValue !== null) {
  41.             return $preValue;
  42.         }
  43.     }
  44.     $data $this->title;
  45.     if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
  46.         return $data->getPlain();
  47.     }
  48.     return $data;
  49. }
  50. /**
  51. * Set title - Titel
  52. * @param string|null $title
  53. * @return \Pimcore\Model\DataObject\Galerie
  54. */
  55. public function setTitle(?string $title)
  56. {
  57.     $this->title $title;
  58.     return $this;
  59. }
  60. /**
  61. * Get images - Bilder
  62. * @return \Pimcore\Model\DataObject\Data\ImageGallery|null
  63. */
  64. public function getImages(): ?\Pimcore\Model\DataObject\Data\ImageGallery
  65. {
  66.     if ($this instanceof PreGetValueHookInterface && !\Pimcore::inAdmin()) {
  67.         $preValue $this->preGetValue("images");
  68.         if ($preValue !== null) {
  69.             return $preValue;
  70.         }
  71.     }
  72.     $data $this->images;
  73.     if ($data instanceof \Pimcore\Model\DataObject\Data\EncryptedField) {
  74.         return $data->getPlain();
  75.     }
  76.     return $data;
  77. }
  78. /**
  79. * Set images - Bilder
  80. * @param \Pimcore\Model\DataObject\Data\ImageGallery|null $images
  81. * @return \Pimcore\Model\DataObject\Galerie
  82. */
  83. public function setImages(?\Pimcore\Model\DataObject\Data\ImageGallery $images)
  84. {
  85.     $this->images $images;
  86.     return $this;
  87. }
  88. }