The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Finance::AMEX::Transaction::GRRCN::Trailer - Parse AMEX Transaction/Invoice Level Reconciliation (GRRCN) Trailer Rows

VERSION

version 0.002

SYNOPSIS

 use Finance::AMEX::Transaction;

 my $epraw = Finance::AMEX::Transaction->new(file_type => 'GRRCN');
 open my $fh, '<', '/path to GRRCN file' or die "cannot open GRRCN file: $!";

 while (my $record = $epraw->getline($fh)) {

  if ($record->type eq 'FOOTER') {
    print $record->RECORD_TYPE . "\n";
  }
 }

 # to parse a single line

 my $record = $epraw->parse_line('line from an GRRCN  file');
 if ($record->type eq 'TRAILER') {
   ...
 }

DESCRIPTION

You would not normally be calling this module directly, it is one of the possible return objects from a call to Finance::AMEX::Transaction's getline method.

METHODS

new

Returns a new Finance::AMEX::Transaction::GRRCN::Trailer object.

 my $record = Finance::AMEX::Transaction::GRRCN::Trailer->new(line => $line);

type

This will always return the string TRAILER.

 print $record->type; # TRAILER

line

Returns the full line that is represented by this object.

 print $record->line;

RECORD_TYPE

This field contains the Record identifier, which will always be “TRAILER” for the Trailer Record.

SEQUENTIAL_NUMBER

This field contains the Sequential Number which is the same as the sequential number in the Header Record.

A sequential number with a prefix of “A” indicates an Adhoc file.

TOTAL_RECORD_COUNT

This field contains the Record Count for all items in this data file, including the Header and Trailer Records. This field is intended to support value verification.

NAME

Finance::AMEX::Transaction::GRRCN::Footer - Object methods for AMEX Reconciliation file footer records.

AUTHOR

Tom Heady <theady@ziprecruiter.com>

COPYRIGHT AND LICENSE

This software is copyright (c) 2018 by ZipRecruiter.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.