public static function WidgetBase::isApplicable in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/lib/Drupal/Core/Field/WidgetBase.php \Drupal\Core\Field\WidgetBase::isApplicable()
Returns if the widget can be used for the provided field.
Parameters
\Drupal\Core\Field\FieldDefinitionInterface $field_definition: The field definition that should be checked.
Return value
bool TRUE if the widget can be used, FALSE otherwise.
Overrides WidgetInterface::isApplicable
1 method overrides WidgetBase::isApplicable()
- TestFieldWidgetMultiple::isApplicable in core/
modules/ field/ tests/ modules/ field_test/ src/ Plugin/ Field/ FieldWidget/ TestFieldWidgetMultiple.php - Used in \Drupal\field\Tests\EntityReference\EntityReferenceAdminTest::testAvailableFormatters().
File
- core/
lib/ Drupal/ Core/ Field/ WidgetBase.php, line 554 - Contains \Drupal\Core\Field\WidgetBase.
Class
- WidgetBase
- Base class for 'Field widget' plugin implementations.
Namespace
Drupal\Core\FieldCode
public static function isApplicable(FieldDefinitionInterface $field_definition) {
// By default, widgets are available for all fields.
return TRUE;
}