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
|
|
2496
|
use strict; |
|
4
|
|
|
|
|
6
|
|
|
4
|
|
|
|
|
132
|
|
10
|
4
|
|
|
4
|
|
39
|
use warnings; |
|
4
|
|
|
|
|
4
|
|
|
4
|
|
|
|
|
118
|
|
11
|
4
|
|
|
4
|
|
14
|
use boolean; |
|
4
|
|
|
|
|
4
|
|
|
4
|
|
|
|
|
23
|
|
12
|
|
|
|
|
|
|
|
13
|
4
|
|
|
4
|
|
273
|
use base 'Salvation::TC::Meta::Type::Parameterized'; |
|
4
|
|
|
|
|
4
|
|
|
4
|
|
|
|
|
1527
|
|
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
|
|
|
|
|
22
|
my $i = 0; |
27
|
25
|
|
|
|
|
26
|
my @clone = (); |
28
|
|
|
|
|
|
|
|
29
|
25
|
|
|
|
|
29
|
foreach my $item ( @$value ) { |
30
|
|
|
|
|
|
|
|
31
|
44
|
|
|
|
|
93
|
$code -> ( $item, $i, \$clone[ $i ] ); |
32
|
|
|
|
|
|
|
|
33
|
38
|
|
|
|
|
42
|
++$i; |
34
|
|
|
|
|
|
|
} |
35
|
|
|
|
|
|
|
|
36
|
19
|
|
|
|
|
34
|
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
|
|
|
24
|
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
|
7
|
my ( $self ) = @_; |
57
|
|
|
|
|
|
|
|
58
|
7
|
|
66
|
|
|
27
|
return $self -> { 'length_type_generator' } //= Salvation::TC -> get( 'ArrayRef' ) -> length_type_generator(); |
59
|
|
|
|
|
|
|
} |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
1; |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
__END__ |