interface DeletedFieldsRepositoryInterface

Same name in other branches
  1. 9 core/lib/Drupal/Core/Field/DeletedFieldsRepositoryInterface.php \Drupal\Core\Field\DeletedFieldsRepositoryInterface
  2. 8.9.x core/lib/Drupal/Core/Field/DeletedFieldsRepositoryInterface.php \Drupal\Core\Field\DeletedFieldsRepositoryInterface
  3. 11.x core/lib/Drupal/Core/Field/DeletedFieldsRepositoryInterface.php \Drupal\Core\Field\DeletedFieldsRepositoryInterface

Provides an interface for a deleted fields repository.

@internal

Hierarchy

Expanded class hierarchy of DeletedFieldsRepositoryInterface

All classes that implement DeletedFieldsRepositoryInterface

2 files declare their use of DeletedFieldsRepositoryInterface
FieldConfigStorage.php in core/modules/field/src/FieldConfigStorage.php
FieldStorageConfigStorage.php in core/modules/field/src/FieldStorageConfigStorage.php

File

core/lib/Drupal/Core/Field/DeletedFieldsRepositoryInterface.php, line 10

Namespace

Drupal\Core\Field
View source
interface DeletedFieldsRepositoryInterface {
    
    /**
     * Returns a list of deleted field definitions.
     *
     * @param string $field_storage_unique_id
     *   (optional) A unique ID of field storage definition for filtering the
     *   deleted fields. Defaults to NULL.
     *
     * @return \Drupal\Core\Field\FieldDefinitionInterface[]
     *   An array of field definition objects, keyed by their unique identifier.
     */
    public function getFieldDefinitions($field_storage_unique_id = NULL);
    
    /**
     * Returns a list of deleted field storage definitions.
     *
     * @return \Drupal\Core\Field\FieldStorageDefinitionInterface[]
     *   An array of field storage definition objects, keyed by their unique
     *   storage identifier.
     */
    public function getFieldStorageDefinitions();
    
    /**
     * Adds a field definition object to the deleted list.
     *
     * @param \Drupal\Core\Field\FieldDefinitionInterface $field_definition
     *   A field definition object.
     *
     * @return $this
     */
    public function addFieldDefinition(FieldDefinitionInterface $field_definition);
    
    /**
     * Adds a field storage definition object to the deleted list.
     *
     * @param \Drupal\Core\Field\FieldStorageDefinitionInterface $field_storage_definition
     *   A field storage definition object.
     *
     * @return $this
     */
    public function addFieldStorageDefinition(FieldStorageDefinitionInterface $field_storage_definition);
    
    /**
     * Removes a field definition object from the deleted list.
     *
     * @param \Drupal\Core\Field\FieldDefinitionInterface $field_definition
     *   A field definition object.
     *
     * @return $this
     */
    public function removeFieldDefinition(FieldDefinitionInterface $field_definition);
    
    /**
     * Removes a field storage definition object from the deleted list.
     *
     * @param \Drupal\Core\Field\FieldStorageDefinitionInterface $field_storage_definition
     *   A field storage definition object.
     *
     * @return $this
     */
    public function removeFieldStorageDefinition(FieldStorageDefinitionInterface $field_storage_definition);

}

Members

Title Sort descending Modifiers Object type Summary
DeletedFieldsRepositoryInterface::addFieldDefinition public function Adds a field definition object to the deleted list.
DeletedFieldsRepositoryInterface::addFieldStorageDefinition public function Adds a field storage definition object to the deleted list.
DeletedFieldsRepositoryInterface::getFieldDefinitions public function Returns a list of deleted field definitions.
DeletedFieldsRepositoryInterface::getFieldStorageDefinitions public function Returns a list of deleted field storage definitions.
DeletedFieldsRepositoryInterface::removeFieldDefinition public function Removes a field definition object from the deleted list.
DeletedFieldsRepositoryInterface::removeFieldStorageDefinition public function Removes a field storage definition object from the deleted list.

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.