3 namespace Drupal\Core\Entity;
6 * Defines a common interface for all content entity objects.
8 * Content entities use fields for all their entity properties and can be
9 * translatable and revisionable. Translations and revisions can be
10 * enabled per entity type through annotation and using entity type hooks.
12 * It's best practice to always implement ContentEntityInterface for
13 * content-like entities that should be stored in some database, and
14 * enable/disable revisions and translations as desired.
16 * When implementing this interface which extends Traversable, make sure to list
17 * IteratorAggregate or Iterator before this interface in the implements clause.
19 * @see \Drupal\Core\Entity\ContentEntityBase
20 * @see \Drupal\Core\Entity\EntityTypeInterface
24 interface ContentEntityInterface extends \Traversable, FieldableEntityInterface, TranslatableRevisionableInterface {