PluginProbe
Depicter — Popup & Slider Builder / trunk
Depicter — Popup & Slider Builder vtrunk
4.8.1 trunk 1.0.0 1.1.0 1.1.2 1.1.4 1.1.6 1.1.7 1.1.8 1.1.9 1.2.0 1.3.0 1.3.1 1.3.2 1.3.3 1.3.5 1.3.8 1.5.0 1.5.1 1.5.2 1.5.5 1.6.0 1.6.1 1.6.2 1.7.0 All 76 releases
depicter / app / src / Document / Models / Traits / EntityPropertiesTrait.php

EntityPropertiesTrait.php in Depicter — Popup & Slider Builder trunk, at app/src/Document/Models/Traits/EntityPropertiesTrait.php

58 lines 926 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 namespace Depicter\Document\Models\Traits;
4
5 trait EntityPropertiesTrait {
6
7 /**
8 * Document entity params
9 *
10 * @var array
11 */
12 private $entityProperties = [];
13
14
15 /**
16 * Sets entity properties
17 *
18 * @param array $properties
19 *
20 * @return void
21 */
22 public function setEntityProperties( $properties = [] )
23 {
24 $this->entityProperties = $properties;
25 }
26
27 /**
28 * Retrieves entity properties
29 *
30 * @return array
31 */
32 public function getEntityProperties()
33 {
34 return $this->entityProperties;
35 }
36
37 /**
38 * Retrieves value of an entity property
39 *
40 * @return string
41 */
42 public function getEntityProperty( $propertyName = '' )
43 {
44 return $this->entityProperties[ $propertyName ] ?? '';
45 }
46
47 /**
48 * Sets an entity property
49 *
50 * @return string
51 */
52 public function setEntityProperty( $propertyName = '', $propertyValue = '' )
53 {
54 return $this->entityProperties[ $propertyName ] = $propertyValue;
55 }
56
57 }
58