line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Finance::AMEX::Transaction::CBNOT::Base 0.005; |
2
|
|
|
|
|
|
|
|
3
|
9
|
|
|
9
|
|
59
|
use strict; |
|
9
|
|
|
|
|
16
|
|
|
9
|
|
|
|
|
207
|
|
4
|
9
|
|
|
9
|
|
37
|
use warnings; |
|
9
|
|
|
|
|
14
|
|
|
9
|
|
|
|
|
1701
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
# ABSTRACT: Parse AMEX Chargeback Notification Files (CBNOT) Base methods |
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
sub new { |
9
|
6
|
|
|
6
|
1
|
23
|
my ($class, %props) = @_; |
10
|
6
|
|
|
|
|
19
|
my $self = bless {_line => $props{line}}, $class; |
11
|
|
|
|
|
|
|
|
12
|
6
|
|
|
|
|
22
|
return $self; |
13
|
|
|
|
|
|
|
} |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
sub line { |
16
|
0
|
|
|
0
|
1
|
0
|
my ($self) = @_; |
17
|
0
|
|
|
|
|
0
|
return $self->{_line}; |
18
|
|
|
|
|
|
|
} |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
sub _get_column { |
21
|
294
|
|
|
294
|
|
638
|
my ($self, $field) = @_; |
22
|
294
|
|
|
|
|
659
|
my $map = $self->field_map->{$field}; |
23
|
|
|
|
|
|
|
|
24
|
294
|
|
|
|
|
3585
|
my $ret = substr($self->{_line}, $map->[0] - 1, $map->[1]); |
25
|
294
|
|
|
|
|
1348
|
$ret =~ s{\s+\z}{}xsm; |
26
|
294
|
|
|
|
|
1785
|
return $ret; |
27
|
|
|
|
|
|
|
} |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
sub REC_TYPE { |
30
|
4
|
|
|
4
|
1
|
1344
|
my ($self) = @_; |
31
|
4
|
|
|
|
|
14
|
return $self->_get_column('REC_TYPE'); |
32
|
|
|
|
|
|
|
} |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
1; |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
__END__ |