function RevisionLogEntityTrait::setRevisionLogMessage

Same name in other branches
  1. 9 core/lib/Drupal/Core/Entity/RevisionLogEntityTrait.php \Drupal\Core\Entity\RevisionLogEntityTrait::setRevisionLogMessage()
  2. 8.9.x core/lib/Drupal/Core/Entity/RevisionLogEntityTrait.php \Drupal\Core\Entity\RevisionLogEntityTrait::setRevisionLogMessage()
  3. 11.x core/lib/Drupal/Core/Entity/RevisionLogEntityTrait.php \Drupal\Core\Entity\RevisionLogEntityTrait::setRevisionLogMessage()

Implements \Drupal\Core\Entity\RevisionLogInterface::setRevisionLogMessage().

1 call to RevisionLogEntityTrait::setRevisionLogMessage()
Media::preSaveRevision in core/modules/media/src/Entity/Media.php
Acts on a revision before it gets saved.

File

core/lib/Drupal/Core/Entity/RevisionLogEntityTrait.php, line 121

Class

RevisionLogEntityTrait
Provides a trait for accessing revision logging and ownership information.

Namespace

Drupal\Core\Entity

Code

public function setRevisionLogMessage($revision_log_message) {
    $this->{$this->getEntityType()
        ->getRevisionMetadataKey('revision_log_message')}->value = $revision_log_message;
    return $this;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.