Drupal 8  8.0.2
FieldStorageDefinitionListener Class Reference
Inheritance diagram for FieldStorageDefinitionListener:

Public Member Functions

 __construct (EntityTypeManagerInterface $entity_type_manager, EventDispatcherInterface $event_dispatcher, EntityLastInstalledSchemaRepositoryInterface $entity_last_installed_schema_repository, EntityFieldManagerInterface $entity_field_manager)
 
 onFieldStorageDefinitionCreate (FieldStorageDefinitionInterface $storage_definition)
 
 onFieldStorageDefinitionUpdate (FieldStorageDefinitionInterface $storage_definition, FieldStorageDefinitionInterface $original)
 
 onFieldStorageDefinitionDelete (FieldStorageDefinitionInterface $storage_definition)
 

Protected Attributes

 $entityTypeManager
 
 $eventDispatcher
 
 $entityLastInstalledSchemaRepository
 
 $entityFieldManager
 

Detailed Description

Reacts to field storage definition CRUD on behalf of the Entity system.

See Also

Constructor & Destructor Documentation

__construct ( EntityTypeManagerInterface  $entity_type_manager,
EventDispatcherInterface  $event_dispatcher,
EntityLastInstalledSchemaRepositoryInterface  $entity_last_installed_schema_repository,
EntityFieldManagerInterface  $entity_field_manager 
)

Constructs a new FieldStorageDefinitionListener.

Parameters
\Drupal\Core\Entity\EntityTypeManagerInterface$entity_type_managerThe entity type manager.
\Symfony\Component\EventDispatcher\EventDispatcherInterface$event_dispatcherThe event dispatcher.
\Drupal\Core\Entity\EntityLastInstalledSchemaRepositoryInterface$entity_last_installed_schema_repositoryThe entity last installed schema repository.
\Drupal\Core\Entity\EntityFieldManagerInterface$entity_field_managerThe entity field manager.

References Drupal\entityTypeManager().

Here is the call graph for this function:

Member Function Documentation

onFieldStorageDefinitionCreate ( FieldStorageDefinitionInterface  $storage_definition)

{Reacts to the creation of a field storage definition.

Parameters
\Drupal\Core\Field\FieldStorageDefinitionInterface$storage_definitionThe definition being created.
}

Implements FieldStorageDefinitionListenerInterface.

References Drupal\entityTypeManager(), and FieldStorageDefinitionInterface\getTargetEntityTypeId().

Here is the call graph for this function:

onFieldStorageDefinitionDelete ( FieldStorageDefinitionInterface  $storage_definition)

{Reacts to the deletion of a field storage definition.

Parameters
\Drupal\Core\Field\FieldStorageDefinitionInterface$storage_definitionThe field being deleted.
}

Implements FieldStorageDefinitionListenerInterface.

References Drupal\entityTypeManager(), and FieldStorageDefinitionInterface\getTargetEntityTypeId().

Here is the call graph for this function:

onFieldStorageDefinitionUpdate ( FieldStorageDefinitionInterface  $storage_definition,
FieldStorageDefinitionInterface  $original 
)

{Reacts to the update of a field storage definition.

Parameters
\Drupal\Core\Field\FieldStorageDefinitionInterface$storage_definitionThe field being updated.
\Drupal\Core\Field\FieldStorageDefinitionInterface$originalThe original storage definition; i.e., the definition before the update.
Exceptions
\Drupal\Core\Entity\Exception\FieldStorageDefinitionUpdateForbiddenExceptionThrown when the update to the field is forbidden.
}

Implements FieldStorageDefinitionListenerInterface.

References Drupal\entityTypeManager(), and FieldStorageDefinitionInterface\getTargetEntityTypeId().

Here is the call graph for this function:


The documentation for this class was generated from the following file: