NAME
IO::Dir::Recursive - IO::Dir working recursive
SYNOPSIS
use IO::Dir::Recursive;
my $dh = IO::Dir::Recursive->new('.');
print "$_\n" while $dh->read();
tie my %dir, 'IO::Dir::Recursive', '.';
print $dir{subdir1}->{subdir2}->{file}->slurp();
DESCRIPTION
IO::Dir::Recursive gives IO::Dir the ability to work recursive.
EXPORT
The following constans may be imported on request.
DIR_NOUPWARDS
This constant can be passed as option to tie to strip out parent directories.
DIR_UNLINK
This is inherited from IO::Dir. Deleting an element from the hash will delete the corresponding file or subdirectory if this constant is passed as a tie option.
METHODS
read
my $item = $dh->read($key);
Returns an item of the $dh structure refered by $key. It return an IO::Dir::Recursive instance for direcory items, an IO::All instance for file items or undef if there's no item called $key.
METHODS
read
my $next = $dh->read();
Reads the next item in $dh and returns a coresponding object: an IO::Dir::Recursive instance for directories, an IO::All instance for files or undef if there are no other items left.
_read
my $next = $dh->_read();
Same as read() above, but returns a string describing the next item instead of an object. Mainly for internal use, but maybe it's useful in some other places, too.
SEE ALSO
Mention other useful documentation such as the documentation of related modules or operating system documentation (such as man pages in UNIX), or any relevant external documentation such as RFCs or standards.
If you have a mailing list set up for your module, mention it here.
If you have a web site set up for your module, mention it here.
AUTHOR
Florian Ragwitz, <rafl@debianforum.de>
COPYRIGHT AND LICENSE
Copyright (C) 2005 by Florian Ragwitz
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.7 or, at your option, any later version of Perl 5 you may have available.
1 POD Error
The following errors were encountered while parsing the POD:
- Around line 55:
You forgot a '=back' before '=head1'