mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
53 lines
1.4 KiB
PHP
53 lines
1.4 KiB
PHP
<?php
|
|
|
|
namespace Chill\PersonBundle\Repository\SocialWork;
|
|
|
|
use Chill\PersonBundle\Entity\SocialWork\SocialAction;
|
|
use Doctrine\ORM\EntityManagerInterface;
|
|
use Doctrine\ORM\EntityRepository;
|
|
use Doctrine\Persistence\ObjectRepository;
|
|
|
|
final class SocialActionRepository implements ObjectRepository
|
|
{
|
|
private EntityRepository $repository;
|
|
|
|
public function __construct(EntityManagerInterface $entityManager)
|
|
{
|
|
$this->repository = $entityManager->getRepository(SocialAction::class);
|
|
}
|
|
|
|
public function find($id, ?int $lockMode = null, ?int $lockVersion = null): ?SocialAction
|
|
{
|
|
return $this->repository->find($id, $lockMode, $lockVersion);
|
|
}
|
|
|
|
/**
|
|
* @return array<int, SocialAction>
|
|
*/
|
|
public function findAll(): array
|
|
{
|
|
return $this->repository->findAll();
|
|
}
|
|
|
|
/**
|
|
* @return array<int, SocialAction>
|
|
*/
|
|
public function findBy(array $criteria, ?array $orderBy = null, $limit = null, $offset = null): array
|
|
{
|
|
return $this->repository->findBy($criteria, $orderBy, $limit, $offset);
|
|
}
|
|
|
|
public function findOneBy(array $criteria, ?array $orderBy = null): ?SocialAction
|
|
{
|
|
return $this->repository->findOneBy($criteria, $orderBy);
|
|
}
|
|
|
|
/**
|
|
* @return class-string
|
|
*/
|
|
public function getClassName(): string
|
|
{
|
|
return SocialAction::class;
|
|
}
|
|
}
|