Upgraded drupal core with security updates
[yaffs-website] / web / core / lib / Drupal / Core / Field / FieldStorageDefinitionListenerInterface.php
1 <?php
2
3 namespace Drupal\Core\Field;
4
5 /**
6  * Defines an interface for reacting to field storage definition creation, deletion, and updates.
7  */
8 interface FieldStorageDefinitionListenerInterface {
9
10   /**
11    * Reacts to the creation of a field storage definition.
12    *
13    * @param \Drupal\Core\Field\FieldStorageDefinitionInterface $storage_definition
14    *   The definition being created.
15    */
16   public function onFieldStorageDefinitionCreate(FieldStorageDefinitionInterface $storage_definition);
17
18   /**
19    * Reacts to the update of a field storage definition.
20    *
21    * @param \Drupal\Core\Field\FieldStorageDefinitionInterface $storage_definition
22    *   The field being updated.
23    * @param \Drupal\Core\Field\FieldStorageDefinitionInterface $original
24    *   The original storage definition; i.e., the definition before the update.
25    *
26    * @throws \Drupal\Core\Entity\Exception\FieldStorageDefinitionUpdateForbiddenException
27    *   Thrown when the update to the field is forbidden.
28    */
29   public function onFieldStorageDefinitionUpdate(FieldStorageDefinitionInterface $storage_definition, FieldStorageDefinitionInterface $original);
30
31   /**
32    * Reacts to the deletion of a field storage definition.
33    *
34    * @param \Drupal\Core\Field\FieldStorageDefinitionInterface $storage_definition
35    *   The field being deleted.
36    */
37   public function onFieldStorageDefinitionDelete(FieldStorageDefinitionInterface $storage_definition);
38
39 }