You are here

public function NullLockBackend::getLockId in Service Container 7

Same name and namespace in other branches
  1. 7.2 lib/Drupal/Core/Lock/NullLockBackend.php \Drupal\Core\Lock\NullLockBackend::getLockId()

Implements Drupal\Core\Lock\LockBackedInterface::getLockId().

Overrides LockBackendInterface::getLockId

File

lib/Drupal/Core/Lock/NullLockBackend.php, line 59
Contains \Drupal\Core\Lock\NullLockBackend.

Class

NullLockBackend
Defines a Null lock backend.

Namespace

Drupal\Core\Lock

Code

public function getLockId() {
  if (!isset($this->lockId)) {
    $this->lockId = uniqid(mt_rand(), TRUE);
  }
  return $this->lockId;
}