| Filesys::Virtual::Async::Plain - A plain non-blocking virtual filesystem |
Filesys::Virtual::Async::Plain - A plain non-blocking virtual filesystem
use Filesys::Virtual::Async::Plain;
my $fs = Filesys::Virtual::Async::Plain->new( root => '/home/foo', );
$fs->mkdir( '/bar', $mode, sub { if ( $_[0] ) { print "success\n"; } else { print "failure:$!\n"; } });
Filesys::Virtual::Async::Plain provides non-blocking access to virtual filesystem rooted in a real filesystem. It's like a chrooted filesytem
This module is still in flux to an extent. It will change. I released this module early due to demand. If you'd like to suggest changes, please drop in the irc channel #poe on irc.perl.org and speak with xantus[] or Apocalypse
root is optional, and defaults to /. root is prepended to all paths after resolution
cwd()
Returns the current working directory (virtual)
root() or root( $path )
Gets or sets the root path
All of these work exactly like the the IO::AIO manpage methods of the same name. Use the IO::AIO manpage as a reference for these functions. This module is mostly a wrapper around the IO::AIO manpage. All paths passed to these functions are resolved for you, so pass virtual paths, not the full path on disk as you would pass to aio
Not an aio method, but a helper that will fetch a list of files in a path, and
optionally stat each file. The callback is called with an array. The first
element is the file name and the second param is an array ref of the return value
of io_stat() if requested.
open()
close()
read()
write()
sendfile()
readahead()
stat()
lstat()
utime()
chown()
truncate()
chmod()
unlink()
mknod()
link()
symlink()
readlink()
rename()
mkdir()
rmdir()
readdir()
load()
copy()
move()
scandir()
rmtree()
fsync()
fdatasync()
the Filesys::Virtual::Async manpage
Probably. Report 'em: http://rt.cpan.org/NoAuth/Bugs.html
David W Davis <xantus@cpan.org>
You can rate this this module at http://cpanratings.perl.org/rate/
Copyright (c) 2009 by David W Davis, All rights reserved
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself
| Filesys::Virtual::Async::Plain - A plain non-blocking virtual filesystem |