line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
=head1 NAME |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
File::OSS::Scan::Constant - define constants |
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
=head1 VERSION |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
version 0.04 |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
=head1 SYNOPSIS |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
use File::OSS::Scan::Constant qw(:all); |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
=head1 DESCRIPTION |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
This is an internal module used by L to get defined constants |
16
|
|
|
|
|
|
|
imported, and should not be called directly. |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
=head1 SEE ALSO |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
=over 4 |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
=item * L |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
=back |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
=head1 AUTHOR |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
Harry Wang |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
This software is Copyright (c) 2014 by Harry Wang. |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
This is free software, licensed under: |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
Artistic License 1.0 |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
=cut |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
package File::OSS::Scan::Constant; |
41
|
|
|
|
|
|
|
|
42
|
1
|
|
|
1
|
|
6
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
31
|
|
43
|
1
|
|
|
1
|
|
5
|
use warnings FATAL => 'all'; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
47
|
|
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
our $VERSION = '0.04'; |
46
|
|
|
|
|
|
|
|
47
|
1
|
|
|
1
|
|
4
|
use base qw(Exporter); |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
90
|
|
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
my @all_constants = do { |
50
|
1
|
|
|
1
|
|
5
|
no strict 'refs'; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
100
|
|
51
|
|
|
|
|
|
|
grep { exists &$_ } keys %{ __PACKAGE__ . '::' }; |
52
|
|
|
|
|
|
|
}; |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
our @EXPORT_OK = ( @all_constants ); |
55
|
|
|
|
|
|
|
our %EXPORT_TAGS = ( all => \@EXPORT_OK ); |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
# ------------------------- |
59
|
|
|
|
|
|
|
# Universal constants |
60
|
|
|
|
|
|
|
# ------------------------- |
61
|
1
|
|
|
1
|
|
3
|
use constant UNI_TRUE => 1; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
61
|
|
62
|
1
|
|
|
1
|
|
3
|
use constant UNI_FALSE => 0; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
79
|
|
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
# ------------------------- |
65
|
|
|
|
|
|
|
# Verbose level |
66
|
|
|
|
|
|
|
# ------------------------- |
67
|
1
|
|
|
1
|
|
26
|
use constant VERBOSE_SILIENT => 0; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
73
|
|
68
|
1
|
|
|
1
|
|
5
|
use constant VERBOSE_NORMAL => 1; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
73
|
|
69
|
1
|
|
|
1
|
|
7
|
use constant VERBOSE_CHATTY => 2; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
45
|
|
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
# ------------------------- |
72
|
|
|
|
|
|
|
# Cache level |
73
|
|
|
|
|
|
|
# ------------------------- |
74
|
1
|
|
|
1
|
|
4
|
use constant CACHE_NONE => 0; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
45
|
|
75
|
1
|
|
|
1
|
|
5
|
use constant CACHE_USE => 1; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
41
|
|
76
|
1
|
|
|
1
|
|
4
|
use constant CACHE_REFRESH => 2; |
|
1
|
|
|
|
|
8
|
|
|
1
|
|
|
|
|
38
|
|
77
|
|
|
|
|
|
|
|
78
|
|
|
|
|
|
|
# ------------------------- |
79
|
|
|
|
|
|
|
# Log formatting constants |
80
|
|
|
|
|
|
|
# ------------------------- |
81
|
1
|
|
|
1
|
|
5
|
use constant WIDTH_FILENAME => 30; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
39
|
|
82
|
1
|
|
|
1
|
|
4
|
use constant WIDTH_SIZE => 10; |
|
1
|
|
|
|
|
45
|
|
|
1
|
|
|
|
|
45
|
|
83
|
1
|
|
|
1
|
|
5
|
use constant WIDTH_MTIME => 20; |
|
1
|
|
|
|
|
32
|
|
|
1
|
|
|
|
|
45
|
|
84
|
1
|
|
|
1
|
|
6
|
use constant WIDTH_BAR => 100; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
36
|
|
85
|
1
|
|
|
1
|
|
4
|
use constant WIDTH_INFO_KEY => 30; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
39
|
|
86
|
1
|
|
|
1
|
|
5
|
use constant WIDTH_INFO_VAL => 100; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
53
|
|
87
|
|
|
|
|
|
|
|
88
|
|
|
|
|
|
|
# ------------------------- |
89
|
|
|
|
|
|
|
# Return status |
90
|
|
|
|
|
|
|
# ------------------------- |
91
|
1
|
|
|
1
|
|
5
|
use constant SUCCESS => 0; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
77
|
|
92
|
1
|
|
|
1
|
|
30
|
use constant FAIL => 99; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
42
|
|
93
|
1
|
|
|
1
|
|
5
|
use constant SKIP => 98; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
37
|
|
94
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
# ------------------------- |
96
|
|
|
|
|
|
|
# level of certainty |
97
|
|
|
|
|
|
|
# ------------------------- |
98
|
1
|
|
|
1
|
|
5
|
use constant CERTAINTY_SURE => 100; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
140
|
|
99
|
|
|
|
|
|
|
|
100
|
|
|
|
|
|
|
|
101
|
|
|
|
|
|
|
|
102
|
|
|
|
|
|
|
|
103
|
|
|
|
|
|
|
1; |