entityManager = $entityManager; } /** * @param string $layer * * @return RepositoryInterface */ public function getRepository(string $layer): RepositoryInterface { $repositoryClassName = LayerClassMap::getClass($layer); return $this->entityManager->getRepository($repositoryClassName); } }