ModelBundle/Repository/NodeRepository.php
public function findNodeIdByIncludedPathSiteId($path, $siteId)
    {
        $qb = $this->createQueryBuilder();
        $qb->field('siteId')->equals($siteId)
            ->field('path')->equals(new MongoRegex('/^'.$path.'(\/.*)?$/'));

        return $qb->getQuery()->execute()->toArray();
    }
public function findNodeIdByIncludedPathSiteId($path, $siteId)
    {
        $qb = $this->createQueryBuilder();
        $qb->field('siteId')->equals($siteId)
            ->field('path')->equals(new MongoRegex('/^'.$path.'(\/.*)?$/'));

        return $qb->getQuery()->execute()->toArray();
    }
public function findNodeIdByIncludedPathSiteId ( $ path , $ siteId ) { $ qb = $ this -> createQueryBuilder ( ) ; $ qb -> field ( 'siteId' ) -> equals ( $ siteId ) -> field ( 'path' ) -> equals ( new MongoRegex ( '/^' . $ path . '(\/.*)?$/' ) ) ; return $ qb -> getQuery ( ) -> execute ( ) -> toArray ( ) ; }
@param string $path
@param string $siteId
@param string $language

@throws \Doctrine\ODM\MongoDB\MongoDBException

@return array
@param string $path @param string $siteId @param string $language