Perl Diver 2.31
Main Environment Variables Perl Default Values Perl Config - Summary Perl Config - Full Installed Modules List Directory uptime Docs

Module Documentation
Details and documentation about a specific module, including version and documentation (if available). Note that while links to perldoc.com and search.cpan.org are provided, the module may be part of a larger distribution. If you reach a File Not Found page on either site, please try the parent module.

SelectSaver

Name SelectSaver
Version 1.02
Located at /usr/share/perl5
File /usr/share/perl5/SelectSaver.pm
Is Core Yes
Search CPAN for this module SelectSaver
Documentation SelectSaver
Module Details SelectSaver

NAME

SelectSaver - save and restore selected file handle


SYNOPSIS

    use SelectSaver;
    {
       my $saver = SelectSaver->new(FILEHANDLE);
       # FILEHANDLE is selected
    }
    # previous handle is selected
    {
       my $saver = SelectSaver->new;
       # new handle may be selected, or not
    }
    # previous handle is selected


DESCRIPTION

A SelectSaver object contains a reference to the file handle that was selected when it was created. If its new method gets an extra parameter, then that parameter is selected; otherwise, the selected file handle remains unchanged.

When a SelectSaver is destroyed, it re-selects the file handle that was selected when it was created.

Perl Diver brought to you by ScriptSolutions.com © 1997- 2024