public function __construct(array $attributes)
{
if (isset($attributes['name'])) {
$this->setName($attributes['name']);
}
if (isset($attributes['text'])) {
$this->setText($attributes['text']);
}
if (isset($attributes['style'])) {
$this->setStyle($attributes['style']);
}
if (isset($attributes['type'])) {
$this->setType($attributes['type']);
}
if (isset($attributes['value'])) {
$this->setValue($attributes['value']);
}
if (isset($attributes['confirm'])) {
$this->setConfirm($attributes['confirm']);
}
}