19 Jan 2005 21:13:53 UTC
- Distribution: IO-Automatic
- Module version: 0.03
- Source (raw)
- Browse (raw)
- How to Contribute
- Testers (489 / 0 / 0)
- KwaliteeBus factor: 0
- 40.74% Coverage
- License: perl_5
- Activity24 month
- Download (2.4KB)
- MetaCPAN Explorer
- Subscribe to distribution
- This version
- Latest versionRCLAMP Richard Clamp
IO::Automatic - automatically choose a suitable IO::* module
use IO::Automatic; # scalar my $scalar; my $io = IO::Automatic->new( \$scalar ); print $io "Hello World\n";
IO::Automatic provides a simple factory for creating new output handles.
Several types of automatic conversion are supplied. If no conversion can be done, we return false. Only the first argument is examined to determine, but all the arguments will be passed through so you can also supply file mode specifications.
Scalar references are translated into IO::Scalar objects.
Globs are returned untouched as it is assumed they will already be suitable for use as IO handles.
A plain scalar is assumed to be a filename and so is transformed into an IO::Zlib or IO::File object as appropriate.
Richard Clamp <email@example.com>
Copyright (C) 2003, 2005 Richard Clamp. All Rights Reserved.
This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
Module Install Instructions
To install IO::Automatic, copy and paste the appropriate command in to your terminal.
perl -MCPAN -e shell install IO::Automatic
For more information on module installation, please visit the detailed CPAN module installation guide.