You are here

public function FieldDefinition::isTranslatable in Drupal 10

Same name and namespace in other branches
  1. 8 core/lib/Drupal/Core/Field/FieldDefinition.php \Drupal\Core\Field\FieldDefinition::isTranslatable()
  2. 9 core/lib/Drupal/Core/Field/FieldDefinition.php \Drupal\Core\Field\FieldDefinition::isTranslatable()

Returns whether the field is translatable.

Return value

bool TRUE if the field is translatable.

Overrides FieldDefinitionInterface::isTranslatable

File

core/lib/Drupal/Core/Field/FieldDefinition.php, line 239

Class

FieldDefinition
A class for defining entity field definitions.

Namespace

Drupal\Core\Field

Code

public function isTranslatable() {
  return !empty($this->definition['translatable']) && $this
    ->getFieldStorageDefinition()
    ->isTranslatable();
}