protected function BackgroundImage::getEntityRepository in Background Image 2.0.x
Same name and namespace in other branches
- 8 src/Entity/BackgroundImage.php \Drupal\background_image\Entity\BackgroundImage::getEntityRepository()
- 2.x src/Entity/BackgroundImage.php \Drupal\background_image\Entity\BackgroundImage::getEntityRepository()
Retrieves the Entity Repository service.
Return value
\Drupal\Core\Entity\EntityRepositoryInterface|mixed
File
- src/
Entity/ BackgroundImage.php, line 327
Class
- BackgroundImage
- Defines the Background Image entity.
Namespace
Drupal\background_image\EntityCode
protected function getEntityRepository() {
if (!isset($this->entityRepository)) {
$this->entityRepository = $this
->getContainer()
->get('entity.repository');
}
return $this->entityRepository;
}