Document/Subscriber/ArticlePageSubscriber.php
private function getPageTitle(ArticleInterface $document)
    {
        $pageTitleProperty = $this->getPageTitleProperty($document);
        if (!$pageTitleProperty) {
            return;
        }

        $stagedData = $document->getStructure()->getStagedData();
        if (array_key_exists($pageTitleProperty->getName(), $stagedData)) {
            return $stagedData[$pageTitleProperty->getName()];
        }

        if (!$document->getStructure()->hasProperty($pageTitleProperty->getName())) {
            return;
        }

        return $document->getStructure()->getProperty($pageTitleProperty->getName())->getValue();
    }
private function getPageTitle(ArticleInterface $document)
    {
        $pageTitleProperty = $this->getPageTitleProperty($document);
        if (!$pageTitleProperty) {
            return;
        }

        $stagedData = $document->getStructure()->getStagedData();
        if (array_key_exists($pageTitleProperty->getName(), $stagedData)) {
            return $stagedData[$pageTitleProperty->getName()];
        }

        if (!$document->getStructure()->hasProperty($pageTitleProperty->getName())) {
            return;
        }

        return $document->getStructure()->getProperty($pageTitleProperty->getName())->getValue();
    }
private function getPageTitle ( ArticleInterface $ document ) { $ pageTitleProperty = $ this -> getPageTitleProperty ( $ document ) ; if ( ! $ pageTitleProperty ) { return ; } $ stagedData = $ document -> getStructure ( ) -> getStagedData ( ) ; if ( array_key_exists ( $ pageTitleProperty -> getName ( ) , $ stagedData ) ) { return $ stagedData [ $ pageTitleProperty -> getName ( ) ] ; } if ( ! $ document -> getStructure ( ) -> hasProperty ( $ pageTitleProperty -> getName ( ) ) ) { return ; } return $ document -> getStructure ( ) -> getProperty ( $ pageTitleProperty -> getName ( ) ) -> getValue ( ) ; }
Returns page-title for node.

@param ArticleInterface $document

@return string
Returns page - title for node .