for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Task\TaskBundle\DoctrineStorage;
use Doctrine\Common\Persistence\ObjectManager;
use Task\Storage\TaskRepositoryInterface;
use Task\TaskBundle\Entity\TaskRepository as ORMTaskRepository;
use Task\TaskInterface;
class TaskRepository implements TaskRepositoryInterface
{
/**
* @var ObjectManager
*/
private $objectManager;
* @var ORMTaskRepository
private $taskRepository;
* {@inheritdoc}
public function add(TaskInterface $task)
$this->objectManager->persist($task);
$this->objectManager->flush();
}
public function findAll()
return $this->taskRepository->findAll();
public function findEndBeforeNow()
return $this->taskRepository->findEndBefore(new \DateTime());