aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/files/node/node.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/files/node/node.php')
-rw-r--r--lib/private/files/node/node.php24
1 files changed, 24 insertions, 0 deletions
diff --git a/lib/private/files/node/node.php b/lib/private/files/node/node.php
index 5df4f738a42..c4fabfc2e2e 100644
--- a/lib/private/files/node/node.php
+++ b/lib/private/files/node/node.php
@@ -356,4 +356,28 @@ class Node implements \OCP\Files\Node {
public function getChecksum() {
return;
}
+
+ /**
+ * @param int $type \OCP\Lock\ILockingProvider::LOCK_SHARED or \OCP\Lock\ILockingProvider::LOCK_EXCLUSIVE
+ * @throws \OCP\Lock\LockedException
+ */
+ public function lock($type) {
+ $this->view->lockFile($this->path, $type);
+ }
+
+ /**
+ * @param int $type \OCP\Lock\ILockingProvider::LOCK_SHARED or \OCP\Lock\ILockingProvider::LOCK_EXCLUSIVE
+ * @throws \OCP\Lock\LockedException
+ */
+ public function changeLock($type) {
+ $this->view->changeLock($this->path, $type);
+ }
+
+ /**
+ * @param int $type \OCP\Lock\ILockingProvider::LOCK_SHARED or \OCP\Lock\ILockingProvider::LOCK_EXCLUSIVE
+ * @throws \OCP\Lock\LockedException
+ */
+ public function unlock($type) {
+ $this->view->unlockFile($this->path, $type);
+ }
}