original_string: public function count($conditions = null, $values = [])
      {
          $res = $this->executeQuery('COUNT(' . $this->key . ') AS num', $conditions, $values)
              ->fetch();
          return (isset($res->num) ? (int)$res->num : 0);
      }
code: public function count($conditions = null, $values = [])
      {
          $res = $this->executeQuery('COUNT(' . $this->key . ') AS num', $conditions, $values)
              ->fetch();
          return (isset($res->num) ? (int)$res->num : 0);
      }
code_tokens: public function count ( $ conditions = null , $ values = [ ] ) { $ res = $ this -> executeQuery ( 'COUNT(' . $ this -> key . ') AS num' , $ conditions , $ values ) -> fetch ( ) ; return ( isset ( $ res -> num ) ? ( int ) $ res -> num : 0 ) ; }
docstring: Count entries, optionally filtered by search criteria.
  
  @param string $conditions    Where conditions.
  @param array  $values        Array of condition values to bind.
  
  @return int                  Number of entries.
docstring_tokens: Count entries optionally filtered by search criteria .