You are here

class PropertyBase in Form Builder 7.2

Hierarchy

Expanded class hierarchy of PropertyBase

2 files declare their use of PropertyBase
Property.php in examples/src/Property.php
Property.php in modules/webform/src/Property.php

File

src/PropertyBase.php, line 5

Namespace

Drupal\form_builder
View source
class PropertyBase implements PropertyInterface {
  protected $property;
  protected $params;
  protected $formTypeName;

  /**
   * {@inheritdoc}
   */
  public function __construct($property, $params, $form_type_name) {
    $this->property = $property;
    $this->params = $params;
    $this->formTypeName = $form_type_name;
  }

  /**
   * {@inheritdoc}
   */
  public function submit($form, &$form_state) {
    if (isset($this->params['submit'])) {
      foreach ($this->params['submit'] as $function) {
        if (function_exists($function)) {
          $function($form, $form_state);
        }
      }
    }
  }

}

Members

Namesort descending Modifiers Type Description Overrides
PropertyBase::$formTypeName protected property 1
PropertyBase::$params protected property 1
PropertyBase::$property protected property 1
PropertyBase::submit public function Submit handler for the editing form(). Overrides PropertyInterface::submit 1
PropertyBase::__construct public function Construct a new instance of this property class. Overrides PropertyInterface::__construct 1