The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

  stag-handle.pl

SYNOPSIS

  stag-handle.pl -w itext -c my-handler.pl myfile.xml > processed.itext

DESCRIPTION

will take a Stag compatible format (xml, sxpr or itext), turn the data into an event stream passing it through my-handler.pl

cat my-handler.pl { person => sub { my ($self, $person) = @_; $person->set_fullname($person->get_firstname . ' ' . $person->get_lastname); }, address => sub { my ($self, $address) = @_; # remove addresses altogether from processed file $address->free; }, }