diff options
author | Robin Appelman <icewind@owncloud.com> | 2013-07-25 16:00:24 +0200 |
---|---|---|
committer | Robin Appelman <icewind@owncloud.com> | 2013-07-25 16:00:24 +0200 |
commit | f4b6a8aa08919a55cff48195725513d58f2d1da9 (patch) | |
tree | 63384dc406b07b1ac48cd730f6f6a5aca8d9b744 /lib/files | |
parent | 4e490b0688bcfff7bd489af039b0db79427fbb94 (diff) | |
download | nextcloud-server-f4b6a8aa08919a55cff48195725513d58f2d1da9.tar.gz nextcloud-server-f4b6a8aa08919a55cff48195725513d58f2d1da9.zip |
add option to wrap existing mounts
Diffstat (limited to 'lib/files')
-rw-r--r-- | lib/files/mount/manager.php | 7 | ||||
-rw-r--r-- | lib/files/mount/mount.php | 7 |
2 files changed, 14 insertions, 0 deletions
diff --git a/lib/files/mount/manager.php b/lib/files/mount/manager.php index 25a5fe241cc..4c432dcf724 100644 --- a/lib/files/mount/manager.php +++ b/lib/files/mount/manager.php @@ -96,6 +96,13 @@ class Manager { } /** + * @return Mount[] + */ + public function getAll() { + return $this->mounts; + } + + /** * Find mounts by numeric storage id * * @param string $id diff --git a/lib/files/mount/mount.php b/lib/files/mount/mount.php index 17b0055ee84..0ce2f5975c7 100644 --- a/lib/files/mount/mount.php +++ b/lib/files/mount/mount.php @@ -138,4 +138,11 @@ class Mount { } return $path; } + + /** + * @param callable $wrapper + */ + public function wrapStorage($wrapper) { + $this->storage = $wrapper($this->mountPoint, $this->storage); + } } |