function EntityBase::GetType in Realistic Dummy Content 8
Get the entity type of the entity being manipulated.
All entities must have a type and a bundle. The type can be node, user, etc. and the bundle can be article, page. In case of a user, there must be a bundle even if there is only one: it is called user, like the entity type.
Return value
The entity type, for example "node" or "user".
1 call to EntityBase::GetType()
- EntityBase::GetBundle in api/
src/ manipulators/ EntityBase.php - Get the bundle of the entity being manipulated.
File
- api/
src/ manipulators/ EntityBase.php, line 78 - Define autoload class.
Class
- EntityBase
- Generic entity manipulator.
Namespace
Drupal\realistic_dummy_content_api\manipulatorsCode
function GetType() {
$return = $this->type
->get('id');
return $return;
}