0
0
Fork 0
mirror of https://github.com/nextcloud/server.git synced 2025-02-27 10:06:31 +00:00
nextcloud_server/lib/private/Lock/NoopLockingProvider.php

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

54 lines
966 B
PHP
Raw Normal View History

2015-05-21 14:11:10 +00:00
<?php
declare(strict_types=1);
2015-05-21 14:11:10 +00:00
/**
* SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors
* SPDX-FileCopyrightText: 2016 ownCloud, Inc.
* SPDX-License-Identifier: AGPL-3.0-only
2015-05-21 14:11:10 +00:00
*/
namespace OC\Lock;
use OCP\Lock\ILockingProvider;
/**
* Locking provider that does nothing.
*
* To be used when locking is disabled.
*/
class NoopLockingProvider implements ILockingProvider {
/**
* {@inheritdoc}
*/
public function isLocked(string $path, int $type): bool {
2015-05-21 14:11:10 +00:00
return false;
}
/**
* {@inheritdoc}
*/
public function acquireLock(string $path, int $type, ?string $readablePath = null): void {
2015-05-21 14:11:10 +00:00
// do nothing
}
/**
* {@inheritdoc}
2015-05-21 14:11:10 +00:00
*/
public function releaseLock(string $path, int $type): void {
2015-05-21 14:11:10 +00:00
// do nothing
}
2015-06-01 11:25:27 +00:00
/**1
* {@inheritdoc}
2015-05-21 14:11:10 +00:00
*/
public function releaseAll(): void {
2015-05-21 14:11:10 +00:00
// do nothing
}
2015-06-01 11:25:27 +00:00
/**
* {@inheritdoc}
*/
public function changeLock(string $path, int $targetType): void {
2015-06-01 11:25:27 +00:00
// do nothing
}
2015-05-21 14:11:10 +00:00
}