abstract class EditorialContentEntityBase in Drupal 10
Same name and namespace in other branches
- 8 core/lib/Drupal/Core/Entity/EditorialContentEntityBase.php \Drupal\Core\Entity\EditorialContentEntityBase
- 9 core/lib/Drupal/Core/Entity/EditorialContentEntityBase.php \Drupal\Core\Entity\EditorialContentEntityBase
Provides a base entity class with extended revision and publishing support.
Hierarchy
- class \Drupal\Core\Entity\EntityBase implements EntityInterface uses RefinableCacheableDependencyTrait, DependencySerializationTrait
- class \Drupal\Core\Entity\ContentEntityBase implements \Drupal\Core\Entity\IteratorAggregate, ContentEntityInterface, TranslationStatusInterface uses EntityChangesDetectionTrait, SynchronizableEntityTrait
- class \Drupal\Core\Entity\EditorialContentEntityBase implements EntityChangedInterface, EntityPublishedInterface, RevisionLogInterface uses EntityChangedTrait, EntityPublishedTrait, RevisionLogEntityTrait
- class \Drupal\Core\Entity\ContentEntityBase implements \Drupal\Core\Entity\IteratorAggregate, ContentEntityInterface, TranslationStatusInterface uses EntityChangesDetectionTrait, SynchronizableEntityTrait
Expanded class hierarchy of EditorialContentEntityBase
Related topics
5 files declare their use of EditorialContentEntityBase
- BlockContent.php in core/
modules/ block_content/ src/ Entity/ BlockContent.php - Media.php in core/
modules/ media/ src/ Entity/ Media.php - MenuLinkContent.php in core/
modules/ menu_link_content/ src/ Entity/ MenuLinkContent.php - Node.php in core/
modules/ node/ src/ Entity/ Node.php - Term.php in core/
modules/ taxonomy/ src/ Entity/ Term.php
File
- core/
lib/ Drupal/ Core/ Entity/ EditorialContentEntityBase.php, line 10
Namespace
Drupal\Core\EntityView source
abstract class EditorialContentEntityBase extends ContentEntityBase implements EntityChangedInterface, EntityPublishedInterface, RevisionLogInterface {
use EntityChangedTrait;
use EntityPublishedTrait;
use RevisionLogEntityTrait;
/**
* {@inheritdoc}
*/
public static function baseFieldDefinitions(EntityTypeInterface $entity_type) {
$fields = parent::baseFieldDefinitions($entity_type);
// Add the revision metadata fields.
$fields += static::revisionLogBaseFieldDefinitions($entity_type);
// Add the published field.
$fields += static::publishedBaseFieldDefinitions($entity_type);
return $fields;
}
}