setDefault(self::DEFAULT_VALUE) ->setSaveType(ZBX_WIDGET_FIELD_TYPE_STR); } /** * @param string $value Reference value. Only numeric characters allowed. */ public function setValue($value): self { if ($value === '' || ctype_alnum((string) $value)) { $this->value = $value; } return $this; } }