diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/filestorage.php | 1 | ||||
-rw-r--r-- | lib/filestorage/local.php | 3 | ||||
-rw-r--r-- | lib/filesystem.php | 3 | ||||
-rw-r--r-- | lib/filesystemview.php | 4 |
4 files changed, 11 insertions, 0 deletions
diff --git a/lib/filestorage.php b/lib/filestorage.php index 71ef4aed00b..bf353bb0cce 100644 --- a/lib/filestorage.php +++ b/lib/filestorage.php @@ -28,6 +28,7 @@ abstract class OC_Filestorage{ abstract public function mkdir($path); abstract public function rmdir($path); abstract public function opendir($path); + abstract public function readdir($path); abstract public function is_dir($path); abstract public function is_file($path); abstract public function stat($path); diff --git a/lib/filestorage/local.php b/lib/filestorage/local.php index 44a2ab0f634..27794fe17c0 100644 --- a/lib/filestorage/local.php +++ b/lib/filestorage/local.php @@ -20,6 +20,9 @@ class OC_Filestorage_Local extends OC_Filestorage{ public function opendir($path){ return opendir($this->datadir.$path); } + public function readdir($handle){ + return readdir($handle); + } public function is_dir($path){ if(substr($path,-1)=='/'){ $path=substr($path,0,-1); diff --git a/lib/filesystem.php b/lib/filesystem.php index 89de533d725..0d0943d3639 100644 --- a/lib/filesystem.php +++ b/lib/filesystem.php @@ -399,6 +399,9 @@ class OC_Filesystem{ static public function opendir($path){ return self::$defaultInstance->opendir($path); } + static public function readdir($path){ + return self::$defaultInstance->readdir($path); + } static public function is_dir($path){ return self::$defaultInstance->is_dir($path); } diff --git a/lib/filesystemview.php b/lib/filesystemview.php index 813a87cd74e..da622bcf920 100644 --- a/lib/filesystemview.php +++ b/lib/filesystemview.php @@ -158,6 +158,10 @@ class OC_FilesystemView { public function opendir($path){ return $this->basicOperation('opendir',$path,array('read')); } + public function readdir($handle){ + $fsLocal= new OC_Filestorage_Local( array( 'datadir' => '/' ) ); + return $fsLocal->readdir( $handle ); + } public function is_dir($path){ if($path=='/'){ return true; |