The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Lufs::Stub - A hello-world filesystem for use with perlufs

DESCRIPTION

This is an example, demonstrating the API. Unless stated otherwise, methods are expected to return 1 for succes, and 0 for failure.

METHODS

init (CONFIG)

CONFIG is a hashref with configuration data, from both lufsd.conf and the -o switch.

mount

This gets called whenever the filesystem is mounted.

umount

This gets called whenever the filesystem is umounted.

stat (FILE, STAT)

STAT is a hash reference. you should fill in the approriate values.

readdir (DIR, LIST)

LIST is an array ref that you should fill. You do not need to push `.' and `..', this will be done for you.

mkdir (DIR, MODE)

MODE is the access mode for the dir that you are creating

open (FILE, MODE)

release (FILE)

read (FILE, OFFSET, COUNT, BUF)

Assign the data to the last argument, return the number of bytes read.

write (FILE, OFFSET, COUNT, BUF)

Return the number of bytes written.

This should return a string: the filename that the link points at.

AUTHOR

Raoul Zwart, <rlzwart@cpan.org>

SEE ALSO

Lufs::Howto, Lufs

COPYRIGHT AND LICENSE

Copyright 2003 by Raoul Zwart

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.