Archive-Extract

 view release on metacpan or  search on metacpan

lib/Archive/Extract.pm  view on Meta::CPAN


=pod

=head1 UTILITY FUNCTION

=head2 type_for($archive)

Given an archive file name, it determins the type by parsing the file
name extension. Used by C<new()> when the C<type> parameter is not passed.
Also useful when the archive file does not include a suffix but the file
name is otherwise known, such as when a file is uploaded to a web server
and stored with a temporary name that differs from the original name, and
you want to use the same detection pattern as Archive::Extract. Example:

  my $ae = Archive::Extract->new(
      archive => '/tmp/02af6s',
      type    => Archive::Extract::type_for('archive.zip'),
  );

=head1 HOW IT WORKS



( run in 3.819 seconds using v1.01-cache-2.11-cpan-b16cb0d3907 )