in reply to Re: What would you like to see in a Virtual Filesystem for Perl?
in thread What would you like to see in a Virtual Filesystem for Perl?

I'm all in favor of adding lots of shortcuts to other modules, like how Path::Class does for File::Temp and so on.

The first idea I get from looking at your modules would be something like making DBIC resultsets out of file trees, like

$fileSet= $path->find( name => qr/.../, size => '>=4000', dir_filter => sub($d) { ... }, ); # Throws an exception unless MIME::Detect is installed $fileSet= $fileSet->find(mime_type => 'text/plain'); my $iter= $fileSet->iter; # depth-first, unless parameter "bfs" given while (&$iter) { ... } # if the list is known to be small my @files= $fileSet->all;
Then your module could adapt those into a SQL query and cache a directory tree, and then use the same path objects to query that database.
  • Comment on Re^2: What would you like to see in a Virtual Filesystem for Perl?
  • Download Code