function LockBackendInterface::lockMayBeAvailable

Same name in other branches
  1. 9 core/lib/Drupal/Core/Lock/LockBackendInterface.php \Drupal\Core\Lock\LockBackendInterface::lockMayBeAvailable()
  2. 8.9.x core/lib/Drupal/Core/Lock/LockBackendInterface.php \Drupal\Core\Lock\LockBackendInterface::lockMayBeAvailable()
  3. 11.x core/lib/Drupal/Core/Lock/LockBackendInterface.php \Drupal\Core\Lock\LockBackendInterface::lockMayBeAvailable()

Checks if a lock is available for acquiring.

Parameters

string $name: Lock to acquire.

Return value

bool

1 call to LockBackendInterface::lockMayBeAvailable()
LockBackendAbstract::wait in core/lib/Drupal/Core/Lock/LockBackendAbstract.php
Waits a short amount of time before a second lock acquire attempt.
4 methods override LockBackendInterface::lockMayBeAvailable()
DatabaseLockBackend::lockMayBeAvailable in core/lib/Drupal/Core/Lock/DatabaseLockBackend.php
Checks if a lock is available for acquiring.
DatabaseLockBackend::lockMayBeAvailable in core/lib/Drupal/Core/ProxyClass/Lock/DatabaseLockBackend.php
Checks if a lock is available for acquiring.
NullLockBackend::lockMayBeAvailable in core/lib/Drupal/Core/Lock/NullLockBackend.php
Checks if a lock is available for acquiring.
PersistentDatabaseLockBackend::lockMayBeAvailable in core/lib/Drupal/Core/ProxyClass/Lock/PersistentDatabaseLockBackend.php
Checks if a lock is available for acquiring.

File

core/lib/Drupal/Core/Lock/LockBackendInterface.php, line 105

Class

LockBackendInterface
Lock backend interface.

Namespace

Drupal\Core\Lock

Code

public function lockMayBeAvailable($name);

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