<?php

namespace App\Repository;

use App\Entity\CommentAnnonce;
use Doctrine\Bundle\DoctrineBundle\Repository\ServiceEntityRepository;
use Doctrine\Persistence\ManagerRegistry;

/**
 * @extends ServiceEntityRepository<CommentAnnonce>
 *
 * @method CommentAnnonce|null find($id, $lockMode = null, $lockVersion = null)
 * @method CommentAnnonce|null findOneBy(array $criteria, array $orderBy = null)
 * @method CommentAnnonce[]    findAll()
 * @method CommentAnnonce[]    findBy(array $criteria, array $orderBy = null, $limit = null, $offset = null)
 */
class CommentAnnonceRepository extends ServiceEntityRepository
{
    public function __construct(ManagerRegistry $registry)
    {
        parent::__construct($registry, CommentAnnonce::class);
    }

//    /**
//     * @return CommentAnnonce[] Returns an array of CommentAnnonce objects
//     */
//    public function findByExampleField($value): array
//    {
//        return $this->createQueryBuilder('c')
//            ->andWhere('c.exampleField = :val')
//            ->setParameter('val', $value)
//            ->orderBy('c.id', 'ASC')
//            ->setMaxResults(10)
//            ->getQuery()
//            ->getResult()
//        ;
//    }

//    public function findOneBySomeField($value): ?CommentAnnonce
//    {
//        return $this->createQueryBuilder('c')
//            ->andWhere('c.exampleField = :val')
//            ->setParameter('val', $value)
//            ->getQuery()
//            ->getOneOrNullResult()
//        ;
//    }
}
