original_string: public function has($id)
      {
          try {
               $em = $this->entityManager->getDoctrineEntityManager();
               $data = $em->getRepository($this->getEntityClass())->findOneBy(array(
                   'id' => $id,
               ));
               
               if ($data !== null) {
                   return true;
               }
               
               return false;
          } catch (\Exception $e) {
              throw new Exception('Cannot check if there is an entity for the given id "' . $id . '".', 0, $e);
          }
      }
code: public function has($id)
      {
          try {
               $em = $this->entityManager->getDoctrineEntityManager();
               $data = $em->getRepository($this->getEntityClass())->findOneBy(array(
                   'id' => $id,
               ));
               
               if ($data !== null) {
                   return true;
               }
               
               return false;
          } catch (\Exception $e) {
              throw new Exception('Cannot check if there is an entity for the given id "' . $id . '".', 0, $e);
          }
      }
code_tokens: public function has ( $ id ) { try { $ em = $ this -> entityManager -> getDoctrineEntityManager ( ) ; $ data = $ em -> getRepository ( $ this -> getEntityClass ( ) ) -> findOneBy ( array ( 'id' => $ id , ) ) ; if ( $ data !== null ) { return true ; } return false ; } catch ( \ Exception $ e ) { throw new Exception ( 'Cannot check if there is an entity for the given id "' . $ id . '".' , 0 , $ e ) ; } }
docstring: Returns true if there is an entity for the given id
  
  @access public
  @param integer $id
  @return boolean
  
  @throws \Zepi\DataSource\Doctrine\Exception Cannot check if there is an entity for the given id "{id}".
docstring_tokens: Returns true if there is an entity for the given id