EntityDefinitionUpdateManager::installEntityType

public EntityDefinitionUpdateManager::installEntityType(EntityTypeInterface $entity_type) Installs a new entity type definition. Parameters \Drupal\Core\Entity\EntityTypeInterface $entity_type: The entity type definition. Overrides EntityDefinitionUpdateManagerInterface::installEntityType File core/lib/Drupal/Core/Entity/EntityDefinitionUpdateManager.php, line 133 Class EntityDefinitionUpdateManager Manages entity definition updates. Namespace Drupal\Core\Entity Code public function i

EntityDefinitionUpdateManager::getFieldStorageDefinition

public EntityDefinitionUpdateManager::getFieldStorageDefinition($name, $entity_type_id) Returns a field storage definition ready to be manipulated. When needing to apply updates to existing field storage definitions, this method should always be used to retrieve a storage definition ready to be manipulated. @todo Make this return a mutable storage definition interface when we have one. See https://www.drupal.org/node/2346329. Parameters string $name: The field name. string $entity_type_id: The

EntityDefinitionUpdateManager::getEntityType

public EntityDefinitionUpdateManager::getEntityType($entity_type_id) Returns an entity type definition ready to be manipulated. When needing to apply updates to existing entity type definitions, this method should always be used to retrieve a definition ready to be manipulated. Parameters string $entity_type_id: The entity type identifier. Return value \Drupal\Core\Entity\EntityTypeInterface The entity type definition. Overrides EntityDefinitionUpdateManagerInterface::getEntityType File core/

EntityDefinitionUpdateManager::getChangeSummary

public EntityDefinitionUpdateManager::getChangeSummary() Gets a human readable summary of the detected changes. Return value array An associative array keyed by entity type id. Each entry is an array of human-readable strings, each describing a change. Overrides EntityDefinitionUpdateManagerInterface::getChangeSummary File core/lib/Drupal/Core/Entity/EntityDefinitionUpdateManager.php, line 44 Class EntityDefinitionUpdateManager Manages entity definition updates. Namespace Drupal\Core\E

EntityDefinitionUpdateManager::getChangeList

protected EntityDefinitionUpdateManager::getChangeList() Gets a list of changes to entity type and field storage definitions. Return value array An associative array keyed by entity type id of change descriptors. Every entry is an associative array with the following optional keys: entity_type: a scalar having only the DEFINITION_UPDATED value. field_storage_definitions: an associative array keyed by field name of scalars having one value among: DEFINITION_CREATED DEFINITION_UPDATED DEFINITI

EntityDefinitionUpdateManager::doFieldUpdate

protected EntityDefinitionUpdateManager::doFieldUpdate($op, $storage_definition = NULL, $original_storage_definition = NULL) Performs a field storage definition update. Parameters string $op: The operation to perform, possible values are static::DEFINITION_CREATED, static::DEFINITION_UPDATED or static::DEFINITION_DELETED. array|null $storage_definition: The new field storage definition. array|null $original_storage_definition: The original field storage definition. File core/lib/Drupal/Core/En

EntityDefinitionUpdateManager::doEntityUpdate

protected EntityDefinitionUpdateManager::doEntityUpdate($op, $entity_type_id) Performs an entity type definition update. Parameters string $op: The operation to perform, either static::DEFINITION_CREATED or static::DEFINITION_UPDATED. string $entity_type_id: The entity type ID. File core/lib/Drupal/Core/Entity/EntityDefinitionUpdateManager.php, line 206 Class EntityDefinitionUpdateManager Manages entity definition updates. Namespace Drupal\Core\Entity Code protected function doEntityU

EntityDefinitionUpdateManager::applyUpdates

public EntityDefinitionUpdateManager::applyUpdates() Applies all the detected valid changes. Use this with care, as it will apply updates for any module, which will lead to unpredictable results. Throws \Drupal\Core\Entity\EntityStorageException This exception is thrown if a change cannot be applied without unacceptable data loss. In such a case, the site administrator needs to apply some other process, such as a custom update function or a migration via the Migrate module. Overrides EntityDef

EntityDefinitionUpdateManager::$entityManager

The entity manager service. Type: \Drupal\Core\Entity\EntityManagerInterface File core/lib/Drupal/Core/Entity/EntityDefinitionUpdateManager.php, line 22 Class EntityDefinitionUpdateManager Manages entity definition updates. Namespace Drupal\Core\Entity Code protected $entityManager;

EntityDefinitionUpdateManager

Manages entity definition updates. Hierarchy class \Drupal\Core\Entity\EntityDefinitionUpdateManager implements EntityDefinitionUpdateManagerInterface uses StringTranslationTrait File core/lib/Drupal/Core/Entity/EntityDefinitionUpdateManager.php, line 14 Namespace Drupal\Core\Entity Members Name Modifiers Type Description EntityDefinitionUpdateManager::$entityManager protected property The entity manager service. EntityDefinitionUpdateManager::applyUpdates public f