protected function WidgetBase::handlesMultipleValues

protected WidgetBase::handlesMultipleValues()

Returns whether the widget handles multiple values.

Return value

bool TRUE if a single copy of formElement() can handle multiple field values, FALSE if multiple values require separate copies of formElement().

File

core/lib/Drupal/Core/Field/WidgetBase.php, line 539

Class

WidgetBase
Base class for 'Field widget' plugin implementations.

Namespace

Drupal\Core\Field

Code

protected function handlesMultipleValues() {
  $definition = $this->getPluginDefinition();
  return $definition['multiple_values'];
}

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Field!WidgetBase.php/function/WidgetBase::handlesMultipleValues/8.1.x