You are here

protected function Element::setProperty in Form Builder 7.2

Set the value of a property.

This method must update the $element for rendering as well as for later storage.

Parameters

string $property: Key of the property.

mixed $value: New value for the property.

Overrides ElementBase::setProperty

File

modules/webform/src/Element.php, line 12

Class

Element

Namespace

Drupal\form_builder_webform

Code

protected function setProperty($property, $value) {
  $component =& $this->element['#webform_component'];
  $properties = $this
    ->getProperties();
  $properties[$property]
    ->setValue($component, $value);
}