line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Perl::Dist::Asset::Module; |
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
27430
|
use strict; |
|
2
|
|
|
|
|
6
|
|
|
2
|
|
|
|
|
78
|
|
4
|
2
|
|
|
2
|
|
12
|
use Carp 'croak'; |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
131
|
|
5
|
2
|
|
|
2
|
|
1042
|
use Params::Util qw{ _STRING _HASH }; |
|
2
|
|
|
|
|
5965
|
|
|
2
|
|
|
|
|
117
|
|
6
|
|
|
|
|
|
|
|
7
|
2
|
|
|
2
|
|
11
|
use vars qw{$VERSION}; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
88
|
|
8
|
|
|
|
|
|
|
BEGIN { |
9
|
2
|
|
|
2
|
|
74
|
$VERSION = '1.16'; |
10
|
|
|
|
|
|
|
} |
11
|
|
|
|
|
|
|
|
12
|
2
|
|
|
|
|
12
|
use Object::Tiny qw{ |
13
|
|
|
|
|
|
|
name |
14
|
|
|
|
|
|
|
type |
15
|
|
|
|
|
|
|
force |
16
|
|
|
|
|
|
|
extras |
17
|
2
|
|
|
2
|
|
832
|
}; |
|
2
|
|
|
|
|
311
|
|
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
##################################################################### |
24
|
|
|
|
|
|
|
# Constructor |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
sub new { |
27
|
1
|
|
|
1
|
0
|
19
|
my $self = shift->SUPER::new(@_); |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
# Apply defaults |
30
|
1
|
50
|
|
|
|
29
|
$self->{force} = $self->force ? 1 : 0; # Needs to be numeric |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
# Check params |
33
|
1
|
50
|
|
|
|
28
|
unless ( _STRING($self->name) ) { |
34
|
0
|
|
|
|
|
0
|
croak("Missing or invalid name param"); |
35
|
|
|
|
|
|
|
} |
36
|
|
|
|
|
|
|
|
37
|
1
|
|
|
|
|
8
|
return $self; |
38
|
|
|
|
|
|
|
} |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
##################################################################### |
45
|
|
|
|
|
|
|
# Support Methods |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
sub trace { |
48
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
49
|
0
|
0
|
|
|
|
|
if ( _CODELIKE($self->{trace}) ) { |
50
|
0
|
|
|
|
|
|
$self->{trace}->(@_); |
51
|
|
|
|
|
|
|
} else { |
52
|
0
|
|
|
|
|
|
print $_[0]; |
53
|
|
|
|
|
|
|
} |
54
|
|
|
|
|
|
|
} |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
1; |