You are here

public function DatabaseLockBackend::lockMayBeAvailable in Drupal 9

Same name in this branch
  1. 9 core/lib/Drupal/Core/Lock/DatabaseLockBackend.php \Drupal\Core\Lock\DatabaseLockBackend::lockMayBeAvailable()
  2. 9 core/lib/Drupal/Core/ProxyClass/Lock/DatabaseLockBackend.php \Drupal\Core\ProxyClass\Lock\DatabaseLockBackend::lockMayBeAvailable()
Same name and namespace in other branches
  1. 8 core/lib/Drupal/Core/ProxyClass/Lock/DatabaseLockBackend.php \Drupal\Core\ProxyClass\Lock\DatabaseLockBackend::lockMayBeAvailable()

Checks if a lock is available for acquiring.

Parameters

string $name: Lock to acquire.

Return value

bool

Overrides LockBackendInterface::lockMayBeAvailable

File

core/lib/Drupal/Core/ProxyClass/Lock/DatabaseLockBackend.php, line 81

Class

DatabaseLockBackend
Provides a proxy class for \Drupal\Core\Lock\DatabaseLockBackend.

Namespace

Drupal\Core\ProxyClass\Lock

Code

public function lockMayBeAvailable($name) {
  return $this
    ->lazyLoadItself()
    ->lockMayBeAvailable($name);
}