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
Path::Extended::Entity(3) User Contributed Perl Documentation Path::Extended::Entity(3)

Path::Extended::Entity

  use Path::Extended::File;
  my $file = Path::Extended::File->new('path/to/some.file');

This is a base class for Path::Extended::File and Path::Extended::Dir.

creates an appropriate object. Note that this base class itself doesn't hold anything.

may take an optional hash, and returns an absolute path of the file/directory. Note that back slashes in the path will be converted to forward slashes unless you explicitly set a "native" option to true.

may take an optional hash, and returns a relative path of the file/directory (compared to the current directory (Cwd::cwd) by default, but you may change this bahavior by passing a "base" option). Note that back slashes in the path will be converted to forward slashes unless you explicitly set a "native" option to true.

returns if the path you passed to the constructor was absolute or not (note that the path stored in an object is always absolute).

returns if the object represents directory or not.

does a physical cleanup of the path with Cwd::realpath, that means, resolves a symbolic link if necessary. Note that this method may croak (when the path does not exist).

copies the file/directory to the destination by "File::Copy::copy".

moves the file/directory to the destination by "File::Copy::move". If the file/directory is open, it'll automatically close.

renames the file/directory. If the file/directory is open, it'll automatically close. If your OS allows rename of an open file, you may want to use built-in "rename" function for better atomicity.
unlinks the file/directory. The same thing can be said as for the "rename_to" method.

returns true if the file/directory exists.

returns true if the file/directory is readable/writable.

returns true if the file/directory is open.

returns a File::stat object for the file/directory.

returns a Path::Extended::Dir object that points to the parent directory of the file/directory.

explicitly returns a path string.

You may optionally pass a logger object with "log" method that accepts "( label => @log_messages )" array arguments to notifty when some (usually unfavorable) thing occurs. By default, a built-in Carp logger will be used. If you want to disable logging, set a false value to "logger". See Log::Dump for details, and for how to use "logfile" and "logfilter" methods.

Path::Extended, Path::Extended::File, Path::Extended::Dir, Log::Dump

Kenichi Ishigaki, <ishigaki@cpan.org>

Copyright (C) 2008 by Kenichi Ishigaki.

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

2014-08-16 perl v5.32.1

Search for    or go to Top of page |  Section 3 |  Main Index

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