public static function TestHeavierTextPlugin::isApplicable in Diff 8
Returns if the plugin can be used for the provided field.
Parameters
\Drupal\Core\Field\FieldStorageDefinitionInterface $field_definition: The field definition that should be checked.
Return value
bool TRUE if the plugin can be used, FALSE otherwise.
Overrides FieldDiffBuilderBase::isApplicable
File
- tests/
modules/ diff_test/ src/ Plugin/ diff/ Field/ TestHeavierTextPlugin.php, line 44
Class
- TestHeavierTextPlugin
- Test diff builder with heavy weight.
Namespace
Drupal\diff_test\Plugin\diff\FieldCode
public static function isApplicable(FieldStorageDefinitionInterface $field_definition) {
return $field_definition
->getName() == 'test_field' || $field_definition
->getName() == 'test_field_lighter';
}