PluginProbe
The Innovative Form Builder – IvyForms / 1.0
The Innovative Form Builder – IvyForms v1.0
1.5.1 1.5 1.4.1 1.4 trunk 0.1.2 0.2 0.2.1 0.3 0.3.1 0.4 0.5 0.6 0.6.1 0.6.1-backup 0.6.1.1 0.7 0.8 0.8.1 0.8.2 0.9 0.9.1 1.0 1.1 1.1.1 All 27 releases
ivyforms / backend / src / Entity / Field / FieldGeneralSettings.php

FieldGeneralSettings.php in The Innovative Form Builder – IvyForms 1.0, at backend/src/Entity/Field/FieldGeneralSettings.php

297 lines 6.3 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 namespace IvyForms\Entity\Field;
4
5 use IvyForms\ValueObjects\Field\FieldGeneralSettings as FieldGeneralSettingsVO;
6
7 /**
8 * Class FieldGeneralSettings
9 *
10 * Entity wrapper for FieldGeneralSettings ValueObject.
11 */
12 class FieldGeneralSettings
13 {
14 private FieldGeneralSettingsVO $fieldGeneralSettings;
15
16 /**
17 * @param FieldGeneralSettingsVO $fieldGeneralSettings
18 */
19 public function __construct(FieldGeneralSettingsVO $fieldGeneralSettings)
20 {
21 $this->fieldGeneralSettings = $fieldGeneralSettings;
22 }
23
24 /**
25 * @return string
26 */
27 public function getLabel(): string
28 {
29 return $this->fieldGeneralSettings->getLabel();
30 }
31
32 /**
33 * @return bool
34 */
35 public function isRequired(): bool
36 {
37 return $this->fieldGeneralSettings->isRequired();
38 }
39
40 /**
41 * @return string
42 */
43 public function getPlaceholder(): string
44 {
45 return $this->fieldGeneralSettings->getPlaceholder();
46 }
47
48 /**
49 * @return bool
50 */
51 public function isHideLabel(): bool
52 {
53 return $this->fieldGeneralSettings->isHideLabel();
54 }
55
56 /**
57 * @return bool
58 */
59 public function isReadOnly(): bool
60 {
61 return $this->fieldGeneralSettings->isReadOnly();
62 }
63
64 /**
65 * @return string
66 */
67 public function getDescription(): string
68 {
69 return $this->fieldGeneralSettings->getDescription();
70 }
71
72 /**
73 * @return string
74 */
75 public function getRequiredMessage(): string
76 {
77 return $this->fieldGeneralSettings->getRequiredMessage();
78 }
79
80 /**
81 * @return string
82 */
83 public function getCssClasses(): string
84 {
85 return $this->fieldGeneralSettings->getCssClasses();
86 }
87
88 /**
89 * @return bool
90 */
91 public function isShuffleOptions(): bool
92 {
93 return $this->fieldGeneralSettings->isShuffleOptions();
94 }
95
96 /**
97 * @return bool
98 */
99 public function isShowValues(): bool
100 {
101 return $this->fieldGeneralSettings->isShowValues();
102 }
103
104 /**
105 * @return bool
106 */
107 public function isEnableSearch(): bool
108 {
109 return $this->fieldGeneralSettings->isEnableSearch();
110 }
111
112 /**
113 * @return bool
114 */
115 public function isVisible(): bool
116 {
117 return $this->fieldGeneralSettings->isVisible();
118 }
119
120 /**
121 * Get the phone format of the form field.
122 *
123 * @return string The phone format of the form field.
124 */
125 public function getPhoneFormat(): string
126 {
127 return $this->fieldGeneralSettings->getPhoneFormat();
128 }
129
130 /**
131 * Set the phone format of the form field.
132 *
133 * @param string $format The phone format to set.
134 */
135 public function setPhoneFormat(string $format): void
136 {
137 $this->fieldGeneralSettings->setPhoneFormat($format);
138 }
139 /**
140 * Get minimum value constraint.
141 *
142 * @return float|null
143 */
144 public function getMinValue(): ?float
145 {
146 return $this->fieldGeneralSettings->getMinValue();
147 }
148
149 /**
150 * Set minimum value constraint.
151 *
152 * @param float|null $minValue
153 */
154 public function setMinValue(?float $minValue): void
155 {
156 $this->fieldGeneralSettings->setMinValue($minValue);
157 }
158
159 /**
160 * Get maximum value constraint.
161 *
162 * @return float|null
163 */
164 public function getMaxValue(): ?float
165 {
166 return $this->fieldGeneralSettings->getMaxValue();
167 }
168
169 /**
170 * Set maximum value constraint.
171 *
172 * @param float|null $maxValue
173 */
174 public function setMaxValue(?float $maxValue): void
175 {
176 $this->fieldGeneralSettings->setMaxValue($maxValue);
177 }
178
179 /**
180 * Get step increment.
181 * @return float
182 */
183 public function getStep(): float
184 {
185 return $this->fieldGeneralSettings->getStep();
186 }
187
188 /**
189 * Set step increment.
190 * @param float $step
191 */
192 public function setStep(float $step): void
193 {
194 $this->fieldGeneralSettings->setStep($step);
195 }
196
197 /**
198 * Get number format key.
199 * @return string
200 */
201 public function getNumberFormat(): string
202 {
203 return $this->fieldGeneralSettings->getNumberFormat();
204 }
205
206 /**
207 * Set number format key.
208 * @param string $numberFormat
209 */
210 public function setNumberFormat(string $numberFormat): void
211 {
212 $this->fieldGeneralSettings->setNumberFormat($numberFormat);
213 }
214
215 /**
216 * Get the phone auto-detect status of the form field.
217 *
218 * @return bool The phone auto-detect status of the form field.
219 */
220 public function isPhoneAutoDetect(): bool
221 {
222 return $this->fieldGeneralSettings->isPhoneAutoDetect();
223 }
224
225 /**
226 * Set the phone auto-detect status of the form field.
227 *
228 * @param bool $val The phone auto-detect status to set.
229 */
230 public function setPhoneAutoDetect(bool $val): void
231 {
232 $this->fieldGeneralSettings->setPhoneAutoDetect($val);
233 }
234
235 /**
236 * Get showRatingText flag.
237 *
238 * @return bool
239 */
240 public function isShowRatingText(): bool
241 {
242 return $this->fieldGeneralSettings->isShowRatingText();
243 }
244
245 /**
246 * Set showRatingText flag.
247 *
248 * @param bool $val
249 */
250 public function setShowRatingText(bool $val): void
251 {
252 $this->fieldGeneralSettings->setShowRatingText($val);
253 }
254 /**
255 * Get the HTML content of the form field.
256 *
257 * @return string The HTML content.
258 */
259 public function getHtmlContent(): string
260 {
261 return $this->fieldGeneralSettings->getHtmlContent();
262 }
263
264 /**
265 * Set the HTML content of the form field.
266 *
267 * @param string $htmlContent The HTML content to set.
268 */
269 public function setHtmlContent(string $htmlContent): void
270 {
271 $this->fieldGeneralSettings->setHtmlContent($htmlContent);
272 }
273 /**
274 * @return bool
275 */
276 public function isLimitRange(): bool
277 {
278 return $this->fieldGeneralSettings->isLimitRange();
279 }
280
281 /**
282 * @param bool $limitRange
283 */
284 public function setLimitRange(bool $limitRange): void
285 {
286 $this->fieldGeneralSettings->setLimitRange($limitRange);
287 }
288
289 /**
290 * @return array<string, bool|string>
291 */
292 public function toArray(): array
293 {
294 return $this->fieldGeneralSettings->toArray();
295 }
296 }
297