PluginProbe
CSS & JavaScript Toolbox / 11.3
CSS & JavaScript Toolbox v11.3
trunk 0.3 0.8 10 10.1 11 11.2 11.3 11.4 11.5 11.6 11.7 11.8 11.9 11.9.1 12 12.0 12.0.1 12.0.3 12.0.4 12.0.5 12.0.6 12.0.7 6.0 6.0.11 All 60 releases
css-javascript-toolbox / models / block / parameters / parameter.php

parameter.php in CSS & JavaScript Toolbox 11.3, at models/block/parameters/parameter.php

183 lines 2.9 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 *
4 */
5
6 /**
7 *
8 */
9 class CJT_Models_Block_Parameters_Parameter {
10
11 /**
12 * put your comment there...
13 *
14 * @var mixed
15 */
16 protected $contentParameter;
17
18 /**
19 * put your comment there...
20 *
21 * @var mixed
22 */
23 protected $defaultValue;
24
25 /**
26 * put your comment there...
27 *
28 * @var mixed
29 */
30 protected $id;
31
32 /**
33 * put your comment there...
34 *
35 * @var mixed
36 */
37 protected $name;
38
39 /**
40 * put your comment there...
41 *
42 * @var mixed
43 */
44 protected $order;
45
46 /**
47 * put your comment there...
48 *
49 * @var mixed
50 */
51 protected $parent;
52
53 /**
54 * put your comment there...
55 *
56 * @var mixed
57 */
58 protected $required = null;
59
60 /**
61 * put your comment there...
62 *
63 * @var mixed
64 */
65 protected $type;
66
67 /**
68 * put your comment there...
69 *
70 * @var mixed
71 */
72 protected $childs = array();
73
74 /**
75 * put your comment there...
76 *
77 * @param mixed $name
78 * @param mixed $type
79 * @param mixed $required
80 * @param mixed $defaultValue
81 * @param mixed $parent
82 * @param mixed $id
83 * @return CJT_Models_Block_Parameters_Parameter
84 */
85 public function __construct($parameter) {
86 $this->contentParameter = isset($parameter['contentParam']) ? $parameter['contentParam'] : null;
87 $this->defaultValue = isset($parameter['defaultValue']) ? $parameter['defaultValue'] : null;
88 $this->id = isset($parameter['id']) ? $parameter['id'] : null;
89 $this->name = isset($parameter['name']) ? $parameter['name'] : null;
90 $this->parent = isset($parameter['parent']) ? $parameter['parent'] : null;
91 $this->required = isset($parameter['required']) ? $parameter['required'] : null;
92 $this->type = isset($parameter['type']) ? $parameter['type'] : null;
93 $this->order = isset($parameter['order']) ? $parameter['order'] : null;
94 }
95
96 /**
97 * put your comment there...
98 *
99 * @param mixed $childs
100 * @return CJT_Models_Block_Parameters_Parameter
101 */
102 public function addChild($child) {
103 // Add child paramter!
104 $this->childs[$child->getId()] = $child;
105 // Chaining.
106 return $this;
107 }
108
109 /**
110 * put your comment there...
111 *
112 */
113 public function getChilds() {
114 return $this->childs;
115 }
116
117 /**
118 * put your comment there...
119 *
120 */
121 public function getContentParameter() {
122 return $this->contentParameter;
123 }
124
125 /**
126 * put your comment there...
127 *
128 */
129 public function getDefaultValue() {
130 return $this->defaultValue;
131 }
132
133 /**
134 * put your comment there...
135 *
136 */
137 public function getId() {
138 return $this->id;
139 }
140
141 /**
142 * put your comment there...
143 *
144 */
145 public function getOrder() {
146 return $this->order;
147 }
148
149 /**
150 * put your comment there...
151 *
152 * @param mixed $slugIt
153 */
154 public function getName($slugIt = false) {
155 return $slugIt ? strtolower($this->name) : $this->name;
156 }
157
158 /**
159 * put your comment there...
160 *
161 */
162 public function getParent() {
163 return $this->parent;
164 }
165
166 /**
167 * put your comment there...
168 *
169 */
170 public function getRequired() {
171 return $this->required;
172 }
173
174 /**
175 * put your comment there...
176 *
177 */
178 public function getType() {
179 return $this->type;
180 }
181
182 } // End class.
183