line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package FormValidator::Simple::ArrayList; |
2
|
24
|
|
|
24
|
|
157
|
use strict; |
|
24
|
|
|
|
|
45
|
|
|
24
|
|
|
|
|
981
|
|
3
|
24
|
|
|
24
|
|
169
|
use base qw/Class::Accessor::Fast/; |
|
24
|
|
|
|
|
46
|
|
|
24
|
|
|
|
|
4272
|
|
4
|
24
|
|
|
24
|
|
22322
|
use FormValidator::Simple::Iterator; |
|
24
|
|
|
|
|
67
|
|
|
24
|
|
|
|
|
790
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
__PACKAGE__->mk_accessors(qw/records/); |
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
sub new { |
9
|
271
|
|
|
271
|
1
|
1305
|
my $class = shift; |
10
|
271
|
|
|
|
|
705
|
my $self = bless { }, $class; |
11
|
271
|
|
|
|
|
1018
|
$self->records( [ ] ); |
12
|
271
|
|
|
|
|
2326
|
$self->_init(@_); |
13
|
271
|
|
|
|
|
2012
|
return $self; |
14
|
|
|
|
|
|
|
} |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
sub _init { |
17
|
0
|
|
|
0
|
|
0
|
my ($self, @args) = @_; |
18
|
|
|
|
|
|
|
} |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
sub append { |
21
|
227
|
|
|
227
|
0
|
1707
|
my ($self, $record) = @_; |
22
|
227
|
|
|
|
|
329
|
push @{ $self->records }, $record; |
|
227
|
|
|
|
|
537
|
|
23
|
|
|
|
|
|
|
} |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
sub get_record_at { |
26
|
228
|
|
|
228
|
0
|
958
|
my ($self, $index) = @_; |
27
|
228
|
|
|
|
|
558
|
return $self->records->[$index]; |
28
|
|
|
|
|
|
|
} |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
sub records_count { |
31
|
374
|
|
|
374
|
0
|
4890
|
my $self = shift; |
32
|
374
|
|
|
|
|
395
|
return scalar @{ $self->records }; |
|
374
|
|
|
|
|
978
|
|
33
|
|
|
|
|
|
|
} |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
sub iterator { |
36
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
37
|
0
|
|
|
|
|
|
return FormValidator::Simple::Iterator->new($self); |
38
|
|
|
|
|
|
|
} |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
1; |
41
|
|
|
|
|
|
|
__END__ |