| line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
|
1
|
|
|
|
|
|
|
package Business::NAB::Australian::DirectEntry::Report::ValueSummary; |
|
2
|
|
|
|
|
|
|
$Business::NAB::Australian::DirectEntry::Report::ValueSummary::VERSION = '0.03'; |
|
3
|
|
|
|
|
|
|
=head1 NAME |
|
4
|
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
Business::NAB::Australian::DirectEntry::Report::ValueSummary |
|
6
|
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
=head1 SYNOPSIS |
|
8
|
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
=head1 DESCRIPTION |
|
10
|
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
Class for summary record in the Australian Direct Entry Report file |
|
12
|
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
=cut; |
|
14
|
|
|
|
|
|
|
|
|
15
|
3
|
|
|
3
|
|
1195947
|
use strict; |
|
|
3
|
|
|
|
|
6
|
|
|
|
3
|
|
|
|
|
131
|
|
|
16
|
3
|
|
|
3
|
|
16
|
use warnings; |
|
|
3
|
|
|
|
|
7
|
|
|
|
3
|
|
|
|
|
223
|
|
|
17
|
3
|
|
|
3
|
|
21
|
use feature qw/ signatures /; |
|
|
3
|
|
|
|
|
6
|
|
|
|
3
|
|
|
|
|
434
|
|
|
18
|
3
|
|
|
3
|
|
21
|
use Carp qw/ croak /; |
|
|
3
|
|
|
|
|
7
|
|
|
|
3
|
|
|
|
|
226
|
|
|
19
|
|
|
|
|
|
|
|
|
20
|
3
|
|
|
3
|
|
714
|
use Moose; |
|
|
3
|
|
|
|
|
593169
|
|
|
|
3
|
|
|
|
|
25
|
|
|
21
|
|
|
|
|
|
|
extends 'Business::NAB::CSV'; |
|
22
|
3
|
|
|
3
|
|
23442
|
no warnings qw/ experimental::signatures /; |
|
|
3
|
|
|
|
|
7
|
|
|
|
3
|
|
|
|
|
232
|
|
|
23
|
|
|
|
|
|
|
|
|
24
|
3
|
|
|
|
|
1956
|
use Business::NAB::Types qw/ |
|
25
|
|
|
|
|
|
|
add_max_string_attribute |
|
26
|
3
|
|
|
3
|
|
558
|
/; |
|
|
3
|
|
|
|
|
10
|
|
|
27
|
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
=head1 ATTRIBUTES |
|
29
|
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
All are NAB::Type::PositiveInt types, required, except where stated |
|
31
|
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
=over |
|
33
|
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
=item sub_trancode (Str) |
|
35
|
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
=item number_of_items |
|
37
|
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
=item total_of_items |
|
39
|
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
=back |
|
41
|
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
=cut |
|
43
|
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
sub BUILD { |
|
45
|
15
|
|
|
15
|
0
|
60
|
my ( $self ) = @_; |
|
46
|
|
|
|
|
|
|
|
|
47
|
15
|
100
|
|
|
|
933
|
croak( "unsupported record type (@{[ $self->record_type ]})" ) |
|
|
2
|
|
|
|
|
88
|
|
|
48
|
|
|
|
|
|
|
if ( $self->record_type !~ /^5(4|8)|62$/ ); |
|
49
|
|
|
|
|
|
|
} |
|
50
|
|
|
|
|
|
|
|
|
51
|
10
|
|
|
10
|
|
21
|
sub _record_type ( $self ) { return $self->record_type } |
|
|
10
|
|
|
|
|
21
|
|
|
|
10
|
|
|
|
|
17
|
|
|
|
10
|
|
|
|
|
610
|
|
|
52
|
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
has [ qw/ record_type / ] => ( |
|
54
|
|
|
|
|
|
|
is => 'ro', |
|
55
|
|
|
|
|
|
|
isa => 'Int', |
|
56
|
|
|
|
|
|
|
required => 1, |
|
57
|
|
|
|
|
|
|
default => sub { |
|
58
|
|
|
|
|
|
|
'54',; |
|
59
|
|
|
|
|
|
|
}, |
|
60
|
|
|
|
|
|
|
); |
|
61
|
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
sub _attributes { |
|
63
|
21
|
|
|
21
|
|
103
|
return qw/ |
|
64
|
|
|
|
|
|
|
sub_trancode |
|
65
|
|
|
|
|
|
|
number_of_items |
|
66
|
|
|
|
|
|
|
total_of_items |
|
67
|
|
|
|
|
|
|
/; |
|
68
|
|
|
|
|
|
|
} |
|
69
|
|
|
|
|
|
|
|
|
70
|
|
|
|
|
|
|
has [ |
|
71
|
|
|
|
|
|
|
qw/ |
|
72
|
|
|
|
|
|
|
number_of_items |
|
73
|
|
|
|
|
|
|
total_of_items |
|
74
|
|
|
|
|
|
|
/ |
|
75
|
|
|
|
|
|
|
] => ( |
|
76
|
|
|
|
|
|
|
is => 'ro', |
|
77
|
|
|
|
|
|
|
isa => 'NAB::Type::PositiveIntOrZero', |
|
78
|
|
|
|
|
|
|
required => 1, |
|
79
|
|
|
|
|
|
|
); |
|
80
|
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
foreach my $str_attr ( |
|
82
|
|
|
|
|
|
|
grep { $_ !~ /items/ } __PACKAGE__->_attributes |
|
83
|
|
|
|
|
|
|
) { |
|
84
|
|
|
|
|
|
|
__PACKAGE__->add_max_string_attribute( |
|
85
|
|
|
|
|
|
|
$str_attr, |
|
86
|
|
|
|
|
|
|
is => 'ro', |
|
87
|
|
|
|
|
|
|
required => 1, |
|
88
|
|
|
|
|
|
|
); |
|
89
|
|
|
|
|
|
|
} |
|
90
|
|
|
|
|
|
|
|
|
91
|
5
|
|
|
5
|
0
|
16
|
sub is_credit ( $self ) { return $self->record_type eq '54' } |
|
|
5
|
|
|
|
|
10
|
|
|
|
5
|
|
|
|
|
10
|
|
|
|
5
|
|
|
|
|
338
|
|
|
92
|
5
|
|
|
5
|
0
|
12
|
sub is_debit ( $self ) { return $self->record_type eq '58' } |
|
|
5
|
|
|
|
|
12
|
|
|
|
5
|
|
|
|
|
8
|
|
|
|
5
|
|
|
|
|
341
|
|
|
93
|
1
|
|
|
1
|
0
|
3
|
sub is_failed ( $self ) { return $self->record_type eq '62' } |
|
|
1
|
|
|
|
|
4
|
|
|
|
1
|
|
|
|
|
2
|
|
|
|
1
|
|
|
|
|
70
|
|
|
94
|
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
__PACKAGE__->meta->make_immutable; |