1Log::Handler::Output::SUcsreerenC(o3n)tributed Perl DocuLmoegn:t:aHtainodnler::Output::Screen(3)
2
3
4

NAME

6       Log::Handler::Output::Screen - Log messages to the screen.
7

SYNOPSIS

9           use Log::Handler::Output::Screen;
10
11           my $screen = Log::Handler::Output::Screen->new(
12               log_to => "STDERR",
13               dump   => 1,
14           );
15
16           $screen->log($message);
17

DESCRIPTION

19       This output module makes it possible to log messages to your screen.
20

METHODS

22   new()
23       Call "new()" to create a new Log::Handler::Output::Screen object.
24
25       The following options are possible:
26
27       log_to
28           Where do you want to log? Possible is: STDOUT, STDERR and WARN.
29
30           WARN means to call "warn()".
31
32           The default is STDOUT.
33
34       dump
35           Set this option to 1 if you want that the message will be dumped
36           with "Data::Dumper" to the screen.
37
38       utf8, utf-8
39           Set utf8 or utf-8 on STDOUT or STDERR. It depends on the parameter
40           log_to.
41
42               utf8   =  binmode, $fh, ":utf8";
43               utf-8  =  binmode, $fh, "encoding(utf-8)";
44
45           Yes, there is a difference.
46
47           <http://perldoc.perl.org/perldiag.html#Malformed-UTF-8-character-(%25s)>
48
49           <http://perldoc.perl.org/Encode.html#UTF-8-vs.-utf8-vs.-UTF8>
50
51   log()
52       Call "log()" if you want to log a message to the screen.
53
54       Example:
55
56           $screen->log("this message goes to the screen");
57
58   validate()
59       Validate a configuration.
60
61   reload()
62       Reload with a new configuration.
63
64   errstr()
65       This function returns the last error message.
66

PREREQUISITES

68           Data::Dumper
69           Params::Validate
70

EXPORTS

72       No exports.
73

REPORT BUGS

75       Please report all bugs to <jschulz.cpan(at)bloonix.de>.
76
77       If you send me a mail then add Log::Handler into the subject.
78

AUTHOR

80       Jonny Schulz <jschulz.cpan(at)bloonix.de>.
81
83       Copyright (C) 2007-2009 by Jonny Schulz. All rights reserved.
84
85       This program is free software; you can redistribute it and/or modify it
86       under the same terms as Perl itself.
87
88
89
90perl v5.34.0                      2022-01-21   Log::Handler::Output::Screen(3)
Impressum