line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package File::Find::Object::Base; |
2
|
|
|
|
|
|
|
$File::Find::Object::Base::VERSION = '0.3.8'; |
3
|
5
|
|
|
5
|
|
2375
|
use strict; |
|
5
|
|
|
|
|
12
|
|
|
5
|
|
|
|
|
142
|
|
4
|
5
|
|
|
5
|
|
22
|
use warnings; |
|
5
|
|
|
|
|
23
|
|
|
5
|
|
|
|
|
153
|
|
5
|
|
|
|
|
|
|
|
6
|
5
|
|
|
5
|
|
27
|
use integer; |
|
5
|
|
|
|
|
9
|
|
|
5
|
|
|
|
|
22
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
# TODO : |
9
|
|
|
|
|
|
|
# _last_dir_scanned should be defined only for ::PathComp , but we should |
10
|
|
|
|
|
|
|
# add a regression test to test it. |
11
|
|
|
|
|
|
|
# |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
use Class::XSAccessor accessors => { |
14
|
|
|
|
|
|
|
( |
15
|
5
|
|
|
|
|
20
|
map { $_ => $_ } ( |
|
5
|
|
|
|
|
49
|
|
16
|
|
|
|
|
|
|
qw( |
17
|
|
|
|
|
|
|
_last_dir_scanned |
18
|
|
|
|
|
|
|
) |
19
|
|
|
|
|
|
|
) |
20
|
|
|
|
|
|
|
) |
21
|
5
|
|
|
5
|
|
2914
|
}; |
|
5
|
|
|
|
|
12544
|
|
22
|
|
|
|
|
|
|
|
23
|
5
|
|
|
5
|
|
1138
|
use File::Spec; |
|
5
|
|
|
|
|
12
|
|
|
5
|
|
|
|
|
250
|
|
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
# Create a _copy method that does a flat copy of an array returned by |
26
|
|
|
|
|
|
|
# a method as a reference. |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
sub _make_copy_methods |
29
|
|
|
|
|
|
|
{ |
30
|
10
|
|
|
10
|
|
29
|
my ( $pkg, $methods ) = @_; |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
## no critic |
33
|
5
|
|
|
5
|
|
28
|
no strict 'refs'; |
|
5
|
|
|
|
|
16
|
|
|
5
|
|
|
|
|
769
|
|
34
|
10
|
|
|
|
|
30
|
foreach my $method (@$methods) |
35
|
|
|
|
|
|
|
{ |
36
|
15
|
|
|
|
|
89
|
*{ $pkg . "::" . $method . "_copy" } = do |
37
|
15
|
|
|
|
|
62
|
{ |
38
|
15
|
|
|
|
|
26
|
my $m = $method; |
39
|
|
|
|
|
|
|
sub { |
40
|
220
|
|
|
220
|
|
358
|
my $self = shift; |
41
|
220
|
|
|
|
|
318
|
return [ @{ $self->$m(@_) } ]; |
|
220
|
|
|
|
|
1366
|
|
42
|
15
|
|
|
|
|
78
|
}; |
43
|
|
|
|
|
|
|
}; |
44
|
|
|
|
|
|
|
} |
45
|
|
|
|
|
|
|
## use critic |
46
|
10
|
|
|
|
|
31
|
return; |
47
|
|
|
|
|
|
|
} |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
1; |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
__END__ |