Name
setvbuf
Synopsis
$fh->setvbuf(params)
Takes the same parameters as the C function setvbuf(3) and uses the C function to
set the buffering policy for the FileHandle.
The following additional FileHandle methods act as front-ends for the corresponding built-in Perl functions (see the O’Reilly book Programming Perl or the perlfunc manpage for more details):
| |
| |
| |
| |
The next group of FileHandle methods correspond to Perl special variables (see Programming Perl or the perlvar manpage):
| |
| |
| |
| |
| |
| |
Finally, the following methods are useful:
$fh->printSee Perl’s built-in
printfunction.$fh->printfSee Perl’s built-in
printffunction.$fh->getlineWorks like Perl’s
<FILEHANDLE>construct, except that it can be safely called in an array context (but it still returns just one line).$fh->getlinesWorks like Perl’s
<FILEHANDLE>construct when called in an array context to read all remaining lines in a file.
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access