The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.
use XML::SAX::Machines qw( Pipeline );

my @files = @ARGV ? @ARGV : "-";

my $p = Pipeline( XML::Filter::Essex::Foo => \*STDOUT );

for ( @files ) {
    open F, $_ eq "-" ? ">&STDIN" : $_
        or die "$! opening ", $_ eq "-" ? "stdin" : $_, "\n";

    $p->parse_file( \*F );
}