GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  PATH::CLASS::URI (3)

.ds Aq ’

NAME

Path::Class::URI - Serializes and deserializes Path::Class objects as file:// URI

CONTENTS

SYNOPSIS



  use Path::Class;
  use Path::Class::URI;

  my $file = file(bob, john.txt);
  my $uri  = $file->uri; # file:bob/john.txt

  file(, tmp, bar.txt)->uri; # file:///tmp/bar.txt

  my $file = file_from_uri("file:///tmp/bar.txt"); # or URI::file object
  $fh = $file->open;



DESCRIPTION

Path::Class::URI is an extension to Path::Class to serialize file path from and to file:// form URI objects.

This module encodes and decodes non URI-safe characters using its literal byte encodings. If you call uri methods on Win32 Path::File objects, you’ll get local filename encodings.

If you want to avoid that and always use UTF-8 filename encodings in URI, see Path::Class::Unicode bundled in this distribution.

METHODS

uri (Path::Class::Entity)


  $uri = $file->uri;
  $uri = $dir->uri;



returns URI object representing Path::Class file and directory.

from_uri (Path::Class::Entity)


  $file = Path::Class::File->from_uri($uri);
  $dir  = Path::Class::Dir->from_uri($uri);



Deserializes URI object (or string) into Path::Class objects.

file_from_uri, dir_from_uri Shortcuts for those from_uri methods. Exported by default.

AUTHOR

Tatsuhiko Miyagawa <miyagawa@cpan.org>

LICENSE

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

SEE ALSO

Path::Class, URI::file
Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 PATH::CLASS::URI (3) 2008-12-03

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.