public function findContent(Query $query, array $languageFilter = array())
    {
        $query = clone $query;
        $query->filter = $query->filter ?: new Criterion\MatchAll();
        $query->query = $query->query ?: new Criterion\MatchAll();

        $this->coreFilter->apply(
            $query,
            $languageFilter,
            DocumentMapper::DOCUMENT_TYPE_IDENTIFIER_CONTENT
        );

        return $this->resultExtractor->extract(
            $this->gateway->findContent($query, $languageFilter),
            $query->facetBuilders
        );
    }
public function findContent(Query $query, array $languageFilter = array())
    {
        $query = clone $query;
        $query->filter = $query->filter ?: new Criterion\MatchAll();
        $query->query = $query->query ?: new Criterion\MatchAll();

        $this->coreFilter->apply(
            $query,
            $languageFilter,
            DocumentMapper::DOCUMENT_TYPE_IDENTIFIER_CONTENT
        );

        return $this->resultExtractor->extract(
            $this->gateway->findContent($query, $languageFilter),
            $query->facetBuilders
        );
    }
public function findContent ( Query $ query , array $ languageFilter = array ( ) ) { $ query = clone $ query ; $ query -> filter = $ query -> filter ? : new Criterion \ MatchAll ( ) ; $ query -> query = $ query -> query ? : new Criterion \ MatchAll ( ) ; $ this -> coreFilter -> apply ( $ query , $ languageFilter , DocumentMapper :: DOCUMENT_TYPE_IDENTIFIER_CONTENT ) ; return $ this -> resultExtractor -> extract ( $ this -> gateway -> findContent ( $ query , $ languageFilter ) , $ query -> facetBuilders ) ; }
Finds content objects for the given query.

@throws \eZ\Publish\API\Repository\Exceptions\InvalidArgumentException if Query criterion is not applicable to its target

@param \eZ\Publish\API\Repository\Values\Content\Query $query
@param array $languageFilter - a map of language related filters specifying languages query will be performed on.
Also used to define which field languages are loaded for the returned content.
Currently supports: <code>array("languages" => array(<language1>,..), "useAlwaysAvailable" => bool)</code>
useAlwaysAvailable defaults to true to avoid exceptions on missing translations.

@return \eZ\Publish\API\Repository\Values\Content\Search\SearchResult
Finds content objects for the given query .