You are here

public function FormWidgetInterface::isApplicable in Typed Data API enhancements 8

Returns if the widget can be used for the provided data.

Parameters

\Drupal\Core\TypedData\DataDefinitionInterface $definition: The definition of the edited data.

Return value

bool Whether the data can be edited with the widget.

6 methods override FormWidgetInterface::isApplicable()
BrokenWidget::isApplicable in src/Plugin/TypedDataFormWidget/BrokenWidget.php
Returns if the widget can be used for the provided data.
DatetimeRangeWidget::isApplicable in src/Plugin/TypedDataFormWidget/DatetimeRangeWidget.php
Returns if the widget can be used for the provided data.
DatetimeWidget::isApplicable in src/Plugin/TypedDataFormWidget/DatetimeWidget.php
Returns if the widget can be used for the provided data.
SelectWidget::isApplicable in src/Plugin/TypedDataFormWidget/SelectWidget.php
Returns if the widget can be used for the provided data.
TextareaWidget::isApplicable in src/Plugin/TypedDataFormWidget/TextareaWidget.php
Returns if the widget can be used for the provided data.

... See full list

File

src/Widget/FormWidgetInterface.php, line 26

Class

FormWidgetInterface
Interface definition for form widget plugins.

Namespace

Drupal\typed_data\Widget

Code

public function isApplicable(DataDefinitionInterface $definition);