ContentTranslationHandler::checkFieldStorageDefinitionTranslatability

protected ContentTranslationHandler::checkFieldStorageDefinitionTranslatability($field_name)

Checks the field storage definition for translatability support.

Checks whether the given field is defined in the field storage definitions and if its definition specifies it as translatable.

Parameters

string $field_name: The name of the field.

Return value

bool TRUE if translatable field storage definition exists, FALSE otherwise.

File

core/modules/content_translation/src/ContentTranslationHandler.php, line 222

Class

ContentTranslationHandler
Base class for content translation handlers.

Namespace

Drupal\content_translation

Code

protected function checkFieldStorageDefinitionTranslatability($field_name) {
  return array_key_exists($field_name, $this->fieldStorageDefinitions) && $this->fieldStorageDefinitions[$field_name]->isTranslatable();
}
doc_Drupal
2016-10-29 08:58:13
Comments
Leave a Comment

Please login to continue.