src/Sulu/Bundle/SnippetBundle/Snippet/SnippetRepository.php
public function getSnippetsAmount(
        $locale,
        $type = null,
        $search = null,
        $sortBy = null,
        $sortOrder = null
    ) {
        $query = $this->getSnippetsQuery($locale, $type, null, null, $search, $sortBy, $sortOrder);
        $result = $query->execute();

        return count(iterator_to_array($result->getRows()));
    }
public function getSnippetsAmount(
        $locale,
        $type = null,
        $search = null,
        $sortBy = null,
        $sortOrder = null
    ) {
        $query = $this->getSnippetsQuery($locale, $type, null, null, $search, $sortBy, $sortOrder);
        $result = $query->execute();

        return count(iterator_to_array($result->getRows()));
    }
public function getSnippetsAmount ( $ locale , $ type = null , $ search = null , $ sortBy = null , $ sortOrder = null ) { $ query = $ this -> getSnippetsQuery ( $ locale , $ type , null , null , $ search , $ sortBy , $ sortOrder ) ; $ result = $ query -> execute ( ) ; return count ( iterator_to_array ( $ result -> getRows ( ) ) ) ; }
Return snippets amount.

If $type is given then only return the snippets of that type.

@param string $locale
@param string $type Optional snippet type
@param string $search
@param string $sortBy
@param string $sortOrder

@throws \InvalidArgumentException

@return SnippetBridge[]
Return snippets amount .