Parse::AFP - Parser for IBM's Advanced Function Printing document format
This document describes version 0.25 of Parse::AFP, released October 16, 2010.
use Parse::AFP; my $afp = Parse::AFP->new('input.afp'); while (my $rec = $afp->next_member) { print $rec->dump; # ... $rec->refresh; # if modified } $afp->refresh; # if modified $afp->write('output.afp');
This module processes IBM's AFP (Advanced Function Printing) files into an object hierarchy; each object may be individually modified, dumped into binary, or written back to another AFP file.
Running the bundled afpdump.pl on a AFP file will probably explain this module's behaviour better than reading this documentation.
afpdump.pl
Methods below applies to all objects in the objects hierarchy.
Constructor. Takes either a filename, or a scalar reference to content.
Returns the binary representation of the current object.
Takes a filename and writes the binary representation to it.
Regenerate binary representation from in-memory data from the object itself and its members. Also refreshes all uplevel parents.
Returns a list of member objects, if any.
Iterator for member objects.
Returns the parent of this object, or undef if this is the toplevel object.
Each class may define additional accessors, in the form of FieldName and SetFieldName. There are no accessors for the toplevel Parse::AFP object.
FieldName
SetFieldName
To the extent possible under law, 唐鳳 has waived all copyright and related or neighboring rights to Parse-AFP.
This work is published from Taiwan.
http://creativecommons.org/publicdomain/zero/1.0
To install Parse::AFP, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Parse::AFP
CPAN shell
perl -MCPAN -e shell install Parse::AFP
For more information on module installation, please visit the detailed CPAN module installation guide.