1IO::Pager::Unbuffered(3U)ser Contributed Perl DocumentatiIoOn::Pager::Unbuffered(3)
2
3
4

NAME

6       IO::Pager::Unbuffered - Pipe output to PAGER if destination is a TTY
7

SYNOPSIS

9         use IO::Pager::Unbuffered;
10         {
11           local $STDOUT = IO::Pager::Unbuffered::open *STDOUT;
12           print <<"  HEREDOC" ;
13           ...
14           A bunch of text later
15           HEREDOC
16         }
17
18         {
19           # You can also use scalar filehandles...
20           my $token = IO::Pager::Unbuffered::open($FH) or warn($!);
21           print $FH "No globs or barewords for us thanks!\n";
22         }
23
24         {
25           # ...or an object interface
26           my $token = new IO::Pager::Unbuffered;
27
28           $token->print("OO shiny...\n");
29         }
30

DESCRIPTION

32       IO::Pager subclasses are designed to programmatically decide whether or
33       not to pipe a filehandle's output to a program specified in PAGER;
34       determined and set by IO::Pager at runtime if not yet defined.
35
36       See IO::Pager for method details.
37

METHODS

39       All methods are inherited from IO::Pager; except for instantiation.
40

CAVEATS

42       You probably want to do something with SIGPIPE eg;
43
44         eval {
45           $SIG{PIPE} = sub { die };
46           local $STDOUT = IO::Pager::open(*STDOUT);
47
48           while (1) {
49             # Do something
50           }
51         }
52
53         # Do something else
54

SEE ALSO

56       IO::Pager, IO::Pager::Buffered, IO::Pager::Page,
57

AUTHOR

59       Jerrad Pierce <jpierce@cpan.org>
60
61       Florent Angly <florent.angly@gmail.com>
62
63       This module was inspired by Monte Mitzelfelt's IO::Page 0.02
64
65       Significant proddage provided by Tye McQueen.
66
68       Copyright (C) 2003-2012 Jerrad Pierce
69
70       ·   Thou shalt not claim ownership of unmodified materials.
71
72       ·   Thou shalt not claim whole ownership of modified materials.
73
74       ·   Thou shalt grant the indemnity of the provider of materials.
75
76       ·   Thou shalt use and dispense freely without other restrictions.
77
78       Or, if you prefer:
79
80       This library is free software; you can redistribute it and/or modify it
81       under the same terms as Perl itself, either Perl version 5.0 or, at
82       your option, any later version of Perl 5 you may have available.
83
84
85
86perl v5.28.1                      2018-10-11          IO::Pager::Unbuffered(3)
Impressum