for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Kunstmaan\VotingBundle\Helper;
use Doctrine\ORM\EntityManagerInterface;
/**
* Abstract Helper class for Voting
*/
abstract class AbstractVotingHelper
{
* @var EntityManagerInterface
protected $em;
* @var string
protected $repository;
* @param EntityManagerInterface $em
public function __construct(EntityManagerInterface $em)
$this->em = $em;
}
* @param string $reference Reference to filter the votes by
*
* @return array Returns an array of votes
public function byReference($reference)
return $this->em->getRepository($this->repository)
findByReference()
Doctrine\Common\Persistence\ObjectRepository
findBy()
This check marks calls to methods that do not seem to exist on an object.
This is most likely the result of a method being renamed without all references to it being renamed likewise.
->findByReference($reference);
* @param string $reference The reference to filter the votes by
* @return mixed Returns the count
public function countByReference($reference)
->countByReference($reference);
* @return mixed Returns the sum of the values
public function getValueByReference($reference)
->getValueByReference($reference);
This check marks calls to methods that do not seem to exist on an object.
This is most likely the result of a method being renamed without all references to it being renamed likewise.