public function __construct($userId = null, $name = null, $value = null) { $this->userId = $userId; $this->name = $name; $this->value = $value === null ? null : (string) $value; }