function EntityBase::bundle
Same name and namespace in other branches
- 11.x core/lib/Drupal/Core/Entity/EntityBase.php \Drupal\Core\Entity\EntityBase::bundle()
- 9 core/lib/Drupal/Core/Entity/EntityBase.php \Drupal\Core\Entity\EntityBase::bundle()
- 8.9.x core/lib/Drupal/Core/Entity/EntityBase.php \Drupal\Core\Entity\EntityBase::bundle()
Gets the bundle of the entity.
Return value
string The bundle of the entity. Defaults to the entity type ID if the entity type does not make use of different bundles.
Overrides EntityInterface::bundle
5 calls to EntityBase::bundle()
- EntityBase::access in core/
lib/ Drupal/ Core/ Entity/ EntityBase.php - EntityBase::getConfigDependencyName in core/
lib/ Drupal/ Core/ Entity/ EntityBase.php - EntityBase::getListCacheTagsToInvalidate in core/
lib/ Drupal/ Core/ Entity/ EntityBase.php - The list cache tags to invalidate for this entity.
- EntityBase::toUrl in core/
lib/ Drupal/ Core/ Entity/ EntityBase.php - EntityBase::urlRouteParameters in core/
lib/ Drupal/ Core/ Entity/ EntityBase.php - Gets an array of placeholders for this entity.
1 method overrides EntityBase::bundle()
- ContentEntityBase::bundle in core/
lib/ Drupal/ Core/ Entity/ ContentEntityBase.php
File
-
core/
lib/ Drupal/ Core/ Entity/ EntityBase.php, line 143
Class
- EntityBase
- Defines a base entity class.
Namespace
Drupal\Core\EntityCode
public function bundle() {
return $this->entityTypeId;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.