You are here

public function HeartbeatStreamStorage::revisionIds in Heartbeat 8

Gets a list of Heartbeat stream revision IDs for a specific Heartbeat stream.

Parameters

\Drupal\heartbeat\Entity\HeartbeatStreamInterface $entity: The Heartbeat stream entity.

Return value

int[] Heartbeat stream revision IDs (in ascending order).

Overrides HeartbeatStreamStorageInterface::revisionIds

File

src/HeartbeatStreamStorage.php, line 23

Class

HeartbeatStreamStorage
Defines the storage handler class for Heartbeat stream entities.

Namespace

Drupal\heartbeat

Code

public function revisionIds(HeartbeatStreamInterface $entity) {
  return $this->database
    ->query('SELECT vid FROM {heartbeat_stream_revision} WHERE id=:id ORDER BY vid', array(
    ':id' => $entity
      ->id(),
  ))
    ->fetchCol();
}