class EntityTestUpdateStorage
Same name and namespace in other branches
- 11.x core/modules/system/tests/modules/entity_test_update/src/EntityTestUpdateStorage.php \Drupal\entity_test_update\EntityTestUpdateStorage
- 10 core/modules/system/tests/modules/entity_test_update/src/EntityTestUpdateStorage.php \Drupal\entity_test_update\EntityTestUpdateStorage
- 8.9.x core/modules/system/tests/modules/entity_test_update/src/EntityTestUpdateStorage.php \Drupal\entity_test_update\EntityTestUpdateStorage
Helper class for entity update testing.
Hierarchy
- class \Drupal\Core\Entity\EntityHandlerBase uses \Drupal\Core\StringTranslation\StringTranslationTrait, \Drupal\Core\DependencyInjection\DependencySerializationTrait
- class \Drupal\Core\Entity\EntityStorageBase implements \Drupal\Core\Entity\EntityStorageInterface, \Drupal\Core\Entity\EntityHandlerInterface extends \Drupal\Core\Entity\EntityHandlerBase
- class \Drupal\Core\Entity\ContentEntityStorageBase implements \Drupal\Core\Entity\ContentEntityStorageInterface, \Drupal\Core\Entity\DynamicallyFieldableEntityStorageInterface, \Drupal\Core\Entity\BundleEntityStorageInterface extends \Drupal\Core\Entity\EntityStorageBase
- class \Drupal\Core\Entity\Sql\SqlContentEntityStorage implements \Drupal\Core\Entity\Sql\SqlEntityStorageInterface, \Drupal\Core\Entity\Schema\DynamicallyFieldableEntityStorageSchemaInterface, \Drupal\Core\Entity\EntityBundleListenerInterface extends \Drupal\Core\Entity\ContentEntityStorageBase
- class \Drupal\entity_test_update\EntityTestUpdateStorage extends \Drupal\Core\Entity\Sql\SqlContentEntityStorage
- class \Drupal\Core\Entity\Sql\SqlContentEntityStorage implements \Drupal\Core\Entity\Sql\SqlEntityStorageInterface, \Drupal\Core\Entity\Schema\DynamicallyFieldableEntityStorageSchemaInterface, \Drupal\Core\Entity\EntityBundleListenerInterface extends \Drupal\Core\Entity\ContentEntityStorageBase
- class \Drupal\Core\Entity\ContentEntityStorageBase implements \Drupal\Core\Entity\ContentEntityStorageInterface, \Drupal\Core\Entity\DynamicallyFieldableEntityStorageInterface, \Drupal\Core\Entity\BundleEntityStorageInterface extends \Drupal\Core\Entity\EntityStorageBase
- class \Drupal\Core\Entity\EntityStorageBase implements \Drupal\Core\Entity\EntityStorageInterface, \Drupal\Core\Entity\EntityHandlerInterface extends \Drupal\Core\Entity\EntityHandlerBase
Expanded class hierarchy of EntityTestUpdateStorage
See also
File
-
core/
modules/ system/ tests/ modules/ entity_test_update/ src/ EntityTestUpdateStorage.php, line 13
Namespace
Drupal\entity_test_updateView source
class EntityTestUpdateStorage extends SqlContentEntityStorage {
/**
* {@inheritdoc}
*/
protected function saveToDedicatedTables(ContentEntityInterface $entity, $update = TRUE, $names = []) {
// Simulate an error during the 'restore' process of a test entity.
if (\Drupal::state()->get('entity_test_update.throw_exception', FALSE)) {
throw new \Exception('Peekaboo!');
}
parent::saveToDedicatedTables($entity, $update, $names);
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.