stag-handle.pl man page on DragonFly

Man page or keyword search:  
man Server   44335 pages
apropos Keyword Search (all sections)
Output format
DragonFly logo
[printable version]

STAG-HANDLE(1)	      User Contributed Perl Documentation	STAG-HANDLE(1)

NAME
       stag-handle - streams a stag file through a handler into a writer

SYNOPSIS
	 stag-handle -w itext -c my-handler.pl myfile.xml > processed.itext
	 stag-handle -w itext -p My::Parser -m My::Handler 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

       -help|h
	   shows this document

       -module|m PERLMODULE
	   A module that is used to transform the input events the module
	   should inherit from Data::Stag::BaseHandler

       -unit|u NODE_NAME
	   (you should always use this option if you specify -m)

	   this is the unit that gets passed to the handler/transformer. this
	   will get set automatically if you use the the -c, -s or -t options

	   multiple units can be set

	     -u foo -u bar -u boz

       -writer|w WRITER
	   writer for final transformed tree; can be xml, sxpr or itext

       -module|m MODULE
	   perl modules for handling events

       -codefile|c FILE
	   a file containing a perlhashref containing event handlers - see
	   below

       -sub|s PERL
	   a perl hashref containing handlers

       -trap|t ELEMENT=SUB

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

POD ERRORS
       Hey! The above document had some coding errors, which are explained
       below:

       Around line 138:
	   =over should be: '=over' or '=over positive_number'

perl v5.20.2			  2009-12-14			STAG-HANDLE(1)
[top]

List of man pages available for DragonFly

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net