public function getCurrentRoot()
    {
        if (null !== $this->getCurrentPage()) {
            return $this->getCurrentPage()->getRoot();
        } elseif (null === $this->getCurrentSite()) {
            return;
        } else {
            return $this->application->getEntityManager()
                ->getRepository('BackBee\NestedNode\Page')
                ->getRoot($this->getCurrentSite())
            ;
        }
    }
public function getCurrentRoot()
    {
        if (null !== $this->getCurrentPage()) {
            return $this->getCurrentPage()->getRoot();
        } elseif (null === $this->getCurrentSite()) {
            return;
        } else {
            return $this->application->getEntityManager()
                ->getRepository('BackBee\NestedNode\Page')
                ->getRoot($this->getCurrentSite())
            ;
        }
    }
public function getCurrentRoot ( ) { if ( null !== $ this -> getCurrentPage ( ) ) { return $ this -> getCurrentPage ( ) -> getRoot ( ) ; } elseif ( null === $ this -> getCurrentSite ( ) ) { return ; } else { return $ this -> application -> getEntityManager ( ) -> getRepository ( 'BackBee\NestedNode\Page' ) -> getRoot ( $ this -> getCurrentSite ( ) ) ; } }
Return the current root of the page to be rendered.

@return null|BackBee\NestedNode\Page
Return the current root of the page to be rendered .