foreach

foreach These flow-control keywords are documented in Compound Statements in perlsyn.

fork

fork Does a fork(2) system call to create a new process running the same program at the same point. It returns the child pid to the parent process, 0 to the child process, or undef if the fork is unsuccessful. File descriptors (and sometimes locks on those descriptors) are shared, while everything else is copied. On most systems supporting fork(), great care has gone into making it extremely efficient (for example, using copy-on-write technology on data pages), making it the dominant paradigm f

Floating-point Arithmetic

Floating-point Arithmetic While use integer provides integer-only arithmetic, there is no analogous mechanism to provide automatic rounding or truncation to a certain number of decimal places. For rounding to a certain number of digits, sprintf() or printf() is usually the easiest route. See perlfaq4. Floating-point numbers are only approximations to what a mathematician would call real numbers. There are infinitely more reals than floats, so some corners must be cut. For example: printf "%.20g

FindBin - Locate directory of original perl script

NAME SYNOPSIS DESCRIPTION EXPORTABLE VARIABLES KNOWN ISSUES AUTHORS COPYRIGHT NAME FindBin - Locate directory of original perl script SYNOPSIS use FindBin; use lib "$FindBin::Bin/../lib"; or use FindBin qw($Bin); use lib "$Bin/../lib"; DESCRIPTION Locates the full path to the script bin directory to allow the use of paths relative to the bin directory. This allows a user to setup a directory tree for some software with directories <root>/bin and <root>/lib , and then the above

Filter::Util::Call - Perl Source Filter Utility Module

NAME SYNOPSIS DESCRIPTION*use Filter::Util::Call* *import()* *filter_add()* *filter() and anonymous sub* EXAMPLESExample 1: A simple filter. Example 2: Using the context Example 3: Using the context within the filter Example 4: Using filter_del Filter::Simple AUTHOR DATE LICENSE NAME Filter::Util::Call - Perl Source Filter Utility Module SYNOPSIS use Filter::Util::Call ; DESCRIPTION This module provides you with the framework to write Source Filters in Perl. An alternate interface to Fil

Filter::Simple - Simplified source filtering

NAME SYNOPSIS DESCRIPTIONThe Problem A Solution Disabling or changing behaviour All-in-one interface Filtering only specific components of source code Filtering only the code parts of source code Using Filter::Simple with an explicit import subroutine Using Filter::Simple and Exporter together How it works AUTHOR CONTACT COPYRIGHT AND LICENSE NAME Filter::Simple - Simplified source filtering SYNOPSIS # in MyFilter.pm: package MyFilter; use Filter::Simple; FILTER { ... };

filetest - Perl pragma to control the filetest permission operators

NAME SYNOPSIS DESCRIPTIONConsider this carefully The "access" sub-pragma Limitation with regard to _ NAME filetest - Perl pragma to control the filetest permission operators SYNOPSIS $can_perhaps_read = -r "file"; # use the mode bits { use filetest 'access'; # intuit harder $can_really_read = -r "file"; } $can_perhaps_read = -r "file"; # use the mode bits again DESCRIPTION This pragma tells the compiler to change the behaviour of the filetest permission operators, -r -w -x -R -W -

fileno

fileno FILEHANDLE Returns the file descriptor for a filehandle, or undefined if the filehandle is not open. If there is no real file descriptor at the OS level, as can happen with filehandles connected to memory objects via open with a reference for the third argument, -1 is returned. This is mainly useful for constructing bitmaps for select and low-level POSIX tty-handling operations. If FILEHANDLE is an expression, the value is taken as an indirect filehandle, generally its name. You can use

FileHandle - supply object methods for filehandles

NAME SYNOPSIS DESCRIPTION SEE ALSO NAME FileHandle - supply object methods for filehandles SYNOPSIS use FileHandle; $fh = FileHandle->new; if ($fh->open("< file")) { print <$fh>; $fh->close; } $fh = FileHandle->new("> FOO"); if (defined $fh) { print $fh "bar\n"; $fh->close; } $fh = FileHandle->new("file", "r"); if (defined $fh) { print <$fh>; undef $fh; # automatically closes the file } $fh = FileHandle->new("file", O_WR

FileCache - keep more files open than the system permits

NAME SYNOPSIS DESCRIPTION CAVEATS BUGS NAME FileCache - keep more files open than the system permits SYNOPSIS no strict 'refs'; use FileCache; # or use FileCache maxopen => 16; cacheout $mode, $path; # or cacheout $path; print $path @data; $fh = cacheout $mode, $path; # or $fh = cacheout $path; print $fh @data; DESCRIPTION The cacheout function will make sure that there's a filehandle open for reading or writing available as the pathname you give it. It automatically closes and re-open