function ContentEntityStorageBase::loadRevision

Same name in other branches
  1. 9 core/lib/Drupal/Core/Entity/ContentEntityStorageBase.php \Drupal\Core\Entity\ContentEntityStorageBase::loadRevision()
  2. 10 core/lib/Drupal/Core/Entity/ContentEntityStorageBase.php \Drupal\Core\Entity\ContentEntityStorageBase::loadRevision()
  3. 11.x core/lib/Drupal/Core/Entity/ContentEntityStorageBase.php \Drupal\Core\Entity\ContentEntityStorageBase::loadRevision()

Overrides EntityStorageInterface::loadRevision

1 call to ContentEntityStorageBase::loadRevision()
ContentEntityStorageBase::deleteRevision in core/lib/Drupal/Core/Entity/ContentEntityStorageBase.php
Delete a specific entity revision.
1 method overrides ContentEntityStorageBase::loadRevision()
ContentEntityNullStorage::loadRevision in core/lib/Drupal/Core/Entity/ContentEntityNullStorage.php
Load a specific entity revision.

File

core/lib/Drupal/Core/Entity/ContentEntityStorageBase.php, line 550

Class

ContentEntityStorageBase
Base class for content entity storage handlers.

Namespace

Drupal\Core\Entity

Code

public function loadRevision($revision_id) {
    $revisions = $this->loadMultipleRevisions([
        $revision_id,
    ]);
    return isset($revisions[$revision_id]) ? $revisions[$revision_id] : NULL;
}

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