ModelBundle/Repository/NodeRepository.php
public function findOnePublished($nodeId, $language, $siteId)
    {
        $qa = $this->createAggregationQueryBuilderWithSiteIdAndLanguage($siteId, $language);
        $filter = array(
            'status.publishedState' => true,
            'deleted' => false,
            'nodeId' => $nodeId,
        );
        $qa->match($filter);

        return $this->singleHydrateAggregateQuery($qa);
    }
public function findOnePublished($nodeId, $language, $siteId)
    {
        $qa = $this->createAggregationQueryBuilderWithSiteIdAndLanguage($siteId, $language);
        $filter = array(
            'status.publishedState' => true,
            'deleted' => false,
            'nodeId' => $nodeId,
        );
        $qa->match($filter);

        return $this->singleHydrateAggregateQuery($qa);
    }
@param string $nodeId
@param string $language
@param string $siteId

@return mixed