PYX::Sort - Processing PYX data or file and sort element attributes.
use PYX::Sort; my $obj = PYX::Sort->new(%parameters); $obj->parse($pyx, $out); $obj->parse_file($input_file, $out); $obj->parse_handle($input_file_handler, $out);
new(%parameters)
Constructor.
output_handler
Output handler. Default value is \*STDOUT.
parse($pyx[, $out])
Parse PYX text or array of PYX text and print sorted list of element attributes in PYX format. If $out not present, use 'output_handler'. Returns undef.
parse_file($input_file[, $out])
Parse file with PYX data and print sorted list of element attributes in PYX format. If $out not present, use 'output_handler'. Returns undef.
parse_handler($input_file[, $out])
Parse PYX handler print sorted list of element attributes in PYX format. If $out not present, use 'output_handler'. Returns undef.
new(): From Class::Utils::set_params(): Unknown parameter '%s'.
use strict; use warnings; use PYX::Sort; # Example data. my $pyx = <<'END'; (tag Aattr3 value Aattr2 value Aattr1 value -text )tag END # PYX::Sort object. my $obj = PYX::Sort->new; # Parse. $obj->parse($pyx); # Output: # (tag # Aattr1="value" # Aattr2="value" # Aattr3="value" # -text # )tag
Class::Utils, PYX::Parser.
Install the PYX modules.
https://github.com/michal-josef-spacek/PYX-Sort
Michal Josef Špaček mailto:skim@cpan.org
http://skim.cz
© 2011-2023 Michal Josef Špaček
BSD 2-Clause License
0.04
To install PYX::Sort, copy and paste the appropriate command in to your terminal.
cpanm
cpanm PYX::Sort
CPAN shell
perl -MCPAN -e shell install PYX::Sort
For more information on module installation, please visit the detailed CPAN module installation guide.