line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package XAS::Apps::Test::Logger; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
1204
|
use Try::Tiny; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
62
|
|
4
|
|
|
|
|
|
|
use XAS::Class |
5
|
1
|
|
|
|
|
6
|
debug => 0, |
6
|
|
|
|
|
|
|
version => '0.02', |
7
|
|
|
|
|
|
|
base => 'XAS::Lib::App', |
8
|
1
|
|
|
1
|
|
3
|
; |
|
1
|
|
|
|
|
1
|
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
#use Data::Dumper; |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
# ---------------------------------------------------------------------- |
13
|
|
|
|
|
|
|
# Public Methods |
14
|
|
|
|
|
|
|
# ---------------------------------------------------------------------- |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
sub setup { |
17
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
} |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
sub main { |
22
|
0
|
|
|
0
|
1
|
|
my $self = shift; |
23
|
|
|
|
|
|
|
|
24
|
0
|
|
|
|
|
|
$self->setup(); |
25
|
|
|
|
|
|
|
|
26
|
0
|
|
|
|
|
|
$self->log->info('starting up'); |
27
|
0
|
|
|
|
|
|
$self->log->level('debug', 1); |
28
|
0
|
|
|
|
|
|
$self->log->debug('heh debugging is working'); |
29
|
0
|
|
|
|
|
|
$self->log->trace('tracing is working'); |
30
|
|
|
|
|
|
|
|
31
|
0
|
|
|
|
|
|
sleep(10); |
32
|
|
|
|
|
|
|
|
33
|
0
|
|
|
|
|
|
$self->log->info('shutting down'); |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
} |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
# ---------------------------------------------------------------------- |
38
|
|
|
|
|
|
|
# Private Methods |
39
|
|
|
|
|
|
|
# ---------------------------------------------------------------------- |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
1; |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
__END__ |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
=head1 NAME |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
XAS::Apps::Logger - A test for logging |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
=head1 SYNOPSIS |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
use XAS::Apps::Logger; |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
my $app = XAS::Apps::Logger->new(); |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
exit $app->run(); |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
=head1 DESCRIPTION |
58
|
|
|
|
|
|
|
|
59
|
|
|
|
|
|
|
This module is a test for logging. |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
=head1 SEE ALSO |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
=over 4 |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
=item L<XAS|XAS> |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
=back |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
=head1 AUTHOR |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
Kevin L. Esteb, E<lt>kevin@kesteb.usE<gt> |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
Copyright (C) 2014 Kevin L. Esteb |
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
TThis is free software; you can redistribute it and/or modify it under |
78
|
|
|
|
|
|
|
the terms of the Artistic License 2.0. For details, see the full text |
79
|
|
|
|
|
|
|
of the license at http://www.perlfoundation.org/artistic_license_2_0. |
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
=cut |