[#6992] Horde_Vfs rewrite
Summary Horde_Vfs rewrite
Queue Horde Framework Packages
Queue Version HEAD
Type Enhancement
State Accepted
Priority 1. Low
Requester chuck (at) horde (dot) org
Created 2008-06-30 (4829 days ago)
Updated 2009-04-07 (4548 days ago)
Patch No

2008-11-09 01:27:51 Chuck Hagenbuch Comment #2 Reply to this comment
Access to file data should be provided through streams whenever 
possible. Some of the current VFS backends have readStream() methods 
already. MDB2 may provide access to database blobs through streams, 
for reference. Stream support should be added to Horde_Db, as well.
2008-08-01 10:55:26 Jan Schneider State ⇒ Accepted
2008-06-30 05:15:15 Chuck Hagenbuch Comment #1
Type ⇒ Enhancement
State ⇒ New
Priority ⇒ 1. Low
Summary ⇒ Horde_Vfs rewrite
Queue ⇒ Horde Framework Packages
Milestone ⇒
Patch ⇒ No
Reply to this comment

Horde_Vfs_File (allow subclassing and specifying the file class to 

Horde_Vfs_Folder (allow subclassing and specifying the folder class to 

Filtering iterator, but let the adapter do the filter if it can. I.e, 
Horde_Vfs_Filter_Glob -> the file backend can do the glob natively, so 
the result isn't wrapped with that filter. Something like:

$vfs->ls($dir, array(new Horde_Vfs_Filter_Glob('*.php')));

- backend gets the array of filters

- if the backend can apply the filter it does

- otherwise, the resulting Horde_Vfs_Folder_Iterator is wrapped with a 
filtering iterator to apply the filter

- Subclass or copy SplFileObject, some of the DirectoryIterator stuff?

What else can be done with stream wrappers?

php -r "var_dump(stream_get_wrappers());"

array(14) {


   string(3) "php"


   string(4) "file"


   string(4) "data"


   string(4) "http"


   string(3) "ftp"


   string(13) "compress.zlib"


   string(5) "https"


   string(4) "ftps"


   string(10) "ssh2.shell"


   string(9) "ssh2.exec"


   string(11) "ssh2.tunnel"


   string(8) "ssh2.scp"


   string(9) "ssh2.sftp"


   string(3) "zip"


Saved Queries