NAME
Path::Resource - URI/Path::Class combination.
VERSION
Version 0.041
SYNOPSIS
use Path::Resource;
# Map a resource on the local disk to a URI.
# Its (disk) directory is "/var/dir" and its uri is "http://hostname/loc"
my $rsc = new Path::Resource dir => "/var/dir", uri => "http://hostname/loc";
# uri: http://hostname/loc
# dir: /var/dir
my $apple_rsc = $rsc->child("apple");
# uri: http://hostname/loc/apple
# dir: /var/dir/apple
my $banana_txt_rsc = $apple_rsc->child("banana.txt");
# uri: http://hostname/loc/apple/banana.txt
# file: /var/dir/apple/banana.txt
my $size = -s $banana_txt_rsc->file;
redirect($banana_txt_rsc->uri);
- Path::Resource->new
- $rsc->file
- $rsc->dir
- $rsc->clone
- $rsc->child
- $rsc->parent
- $rsc->loc
- $rsc->uri
- $rsc->path
- $rsc->base
AUTHOR
Robert Krimen, <rkrimen at cpan.org>
BUGS
Please report any bugs or feature requests to bug-path-resource at rt.cpan.org
, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Path-Resource. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
SUPPORT
You can find documentation for this module with the perldoc command.
perldoc Path::Resource
You can also look for information at:
AnnoCPAN: Annotated CPAN documentation
CPAN Ratings
RT: CPAN's request tracker
Search CPAN
ACKNOWLEDGEMENTS
COPYRIGHT & LICENSE
Copyright 2007 Robert Krimen, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.