/**
  * Updates UrlInformation with new values if they are not already set.
  *
  * @param UrlInformation $urlInformation The value object to update.
  * @param object         $object         The sitemap element to get values from.
  * @param string         $sitemap        Name of the sitemap being built.
  */
 public function guessValues(UrlInformation $urlInformation, $object, $sitemap)
 {
     if ($urlInformation->getLastModification()) {
         return;
     }
     if ($object instanceof SeoContent) {
         /* @var $object SeoContent */
         $urlInformation->setLastModification(max($object->getUpdatedAt(), $this->recursiveBlockUpdateDate($object->getAdditionalInfoBlock())));
     }
 }
 /**
  * Updates UrlInformation with new values if they are not already set.
  *
  * @param UrlInformation $urlInformation The value object to update.
  * @param object         $object         The sitemap element to get values from.
  * @param string         $sitemap        Name of the sitemap being built.
  */
 public function guessValues(UrlInformation $urlInformation, $object, $sitemap)
 {
     if ($urlInformation->getLastModification()) {
         return;
     }
     if ($object instanceof OnePageContent) {
         /* @var $object OnePageContent */
         $updated = $object->getUpdatedAt();
         foreach ($object->getChildren(true) as $section) {
             /* @var $section OnePageSection */
             $updated = max($updated, $this->sectionUpdateDate($section));
         }
         $urlInformation->setLastModification($updated);
     } elseif ($object instanceof OnePageSection) {
         /* @var $object OnePageSection */
         $urlInformation->setLastModification($this->sectionUpdateDate($object));
     }
 }
 /**
  * Updates UrlInformation with new values if they are not already set.
  *
  * @param UrlInformation $urlInformation The value object to update.
  * @param object         $object         The sitemap element to get values from.
  * @param string         $sitemap        Name of the sitemap being built.
  */
 public function guessValues(UrlInformation $urlInformation, $object, $sitemap)
 {
     if (null !== $urlInformation->getLastModification()) {
         return;
     }
     $className = ClassUtils::getRealClass(get_class($object));
     $manager = $this->managerRegistry->getManagerForClass($className);
     if (!$manager instanceof DocumentManager) {
         return;
     }
     /** @var ClassMetadata $metadata */
     $metadata = $manager->getClassMetadata($className);
     $mixins = $metadata->getMixins();
     if (!in_array('mix:lastModified', $mixins)) {
         return;
     }
     $fieldName = $this->getFieldName($metadata);
     if (null === $fieldName) {
         return;
     }
     $urlInformation->setLastModification($metadata->getFieldValue($object, $fieldName));
 }