|
From: stephan b. <st...@s1...> - 2005-01-01 18:27:26
|
The zip/tar ideas got me thinking about abstracting filesystem:
template <typename FileT, typename DirectoryT>
class FileSystem
{
// throw (IOError) left off for brevity...
FileT getFile( const String & path, ListT & targetList );
DirectoryT getDirectory( const String & path, ListT & targetList );
... various funcs to return iterators, etc. ...
};
That could be extended by:
TraditionalFileSystem (what you and i use)
TarFileSystem
ZipFileSystem
FtpFileSystem
...
???
i know there are existing APIs for doing this type of this (KDE and one
of the stream projects on SF (forgot the name)), but i haven't ever
used them.
--
----- st...@s1... http://s11n.net
"...pleasure is a grace and is not obedient to the commands
of the will." -- Alan W. Watts
|