line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Salvation::TC::Meta::Type::Parameterized::ArrayRef; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
=head1 NAME |
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
Salvation::TC::Meta::Type::Parameterized::ArrayRef - Класс для типа параметризованного ArrayRef. |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
=cut |
8
|
|
|
|
|
|
|
|
9
|
4
|
|
|
4
|
|
2572
|
use strict; |
|
4
|
|
|
|
|
7
|
|
|
4
|
|
|
|
|
142
|
|
10
|
4
|
|
|
4
|
|
17
|
use warnings; |
|
4
|
|
|
|
|
4
|
|
|
4
|
|
|
|
|
109
|
|
11
|
4
|
|
|
4
|
|
16
|
use boolean; |
|
4
|
|
|
|
|
5
|
|
|
4
|
|
|
|
|
24
|
|
12
|
|
|
|
|
|
|
|
13
|
4
|
|
|
4
|
|
288
|
use base 'Salvation::TC::Meta::Type::Parameterized'; |
|
4
|
|
|
|
|
4
|
|
|
4
|
|
|
|
|
1865
|
|
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
=head1 METHODS |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
=cut |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
=head2 iterate( ArrayRef $value, CodeRef $code ) |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
=cut |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
sub iterate { |
24
|
|
|
|
|
|
|
|
25
|
25
|
|
|
25
|
1
|
31
|
my ( $self, $value, $code ) = @_; |
26
|
25
|
|
|
|
|
30
|
my $i = 0; |
27
|
25
|
|
|
|
|
29
|
my @clone = (); |
28
|
|
|
|
|
|
|
|
29
|
25
|
|
|
|
|
36
|
foreach my $item ( @$value ) { |
30
|
|
|
|
|
|
|
|
31
|
44
|
|
|
|
|
98
|
$code -> ( $item, $i, \$clone[ $i ] ); |
32
|
|
|
|
|
|
|
|
33
|
38
|
|
|
|
|
59
|
++$i; |
34
|
|
|
|
|
|
|
} |
35
|
|
|
|
|
|
|
|
36
|
19
|
|
|
|
|
43
|
return \@clone; |
37
|
|
|
|
|
|
|
} |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
=head2 signed_type_generator() |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
=cut |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
sub signed_type_generator { |
44
|
|
|
|
|
|
|
|
45
|
7
|
|
|
7
|
1
|
6
|
my ( $self ) = @_; |
46
|
|
|
|
|
|
|
|
47
|
7
|
|
66
|
|
|
38
|
return $self -> { 'signed_type_generator' } //= Salvation::TC -> get( 'ArrayRef' ) -> signed_type_generator(); |
48
|
|
|
|
|
|
|
} |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
=head2 length_type_generator() |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
=cut |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
sub length_type_generator { |
55
|
|
|
|
|
|
|
|
56
|
7
|
|
|
7
|
1
|
8
|
my ( $self ) = @_; |
57
|
|
|
|
|
|
|
|
58
|
7
|
|
33
|
|
|
29
|
return $self -> { 'length_type_generator' } //= Salvation::TC -> get( 'ArrayRef' ) -> length_type_generator(); |
59
|
|
|
|
|
|
|
} |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
1; |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
__END__ |