public function createQuery(array $criteria = array())
    {
        $class = $this->documentClass.'Query';
        $query = new $class($this);
        $query->criteria($criteria);

        return $query;
    }
public function createQuery(array $criteria = array())
    {
        $class = $this->documentClass.'Query';
        $query = new $class($this);
        $query->criteria($criteria);

        return $query;
    }
public function createQuery ( array $ criteria = array ( ) ) { $ class = $ this -> documentClass . 'Query' ; $ query = new $ class ( $ this ) ; $ query -> criteria ( $ criteria ) ; return $ query ; }
Create a query for the repository document class.

@param array $criteria The criteria for the query (optional).

@return Query The query.

@api
Create a query for the repository document class .