Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

xml::tmx::frompo(3pm) [debian man page]

XML::TMX::FromPO(3pm)					User Contributed Perl Documentation				     XML::TMX::FromPO(3pm)

NAME
XML::TMX::FromPO - Generates a TMX file from a group of PO files SYNOPSIS
use XML::TMX::FromPO; my $conv = new XML::TMX::FromPO(OUTPUT => '%f.tmx'); DESCRIPTION
This module can be used to generate TMX files from a group of PO files. METHODS
The following methods are available: new $tmx = new XML::TMX::FromPO(); Creates a new XML::TMX::FromPO object. Please check the COMMON CONFIGURATION section for details on the options. rec_get_po TODO: Document method parse_dir TODO: Document method create_tmx TODO: Document function clean_tmx TODO: Document method COMMON CONFIGURATION
These configuration options can be passed to all methods in the module: LANG => 'list' A case insensitive list of regular expression separated by whitespaces that matches the code of the languages that are to be processed. Defaults to all. CONVERT => 'iconv -f %t -t utf8 < %f' A string that contains the command to convert a file (%f) from some charset (%t) to Unicode. If none is specified, the module tries to use recode(1), if it fails then the module defaults to iconv(1). OUTPUT => 'x.tmx' The name of the output file. If none is specified it defaults to the standard output. DEBUG => 1 Activate debugging information. Defaults to 0. SEE ALSO
XML::TMX::Writer(3), gettext(1), recode(1), iconv(1) AUTHOR
Paulo Jorge Jesus Silva, <paulojjs@bragatel.pt> COPYRIGHT AND LICENSE
Copyright 2003 by Paulo Jorge Jesus Silva This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. perl v5.14.2 2012-06-06 XML::TMX::FromPO(3pm)

Check Out this Related Man Page

XML::TMX::Reader(3pm)					User Contributed Perl Documentation				     XML::TMX::Reader(3pm)

NAME
XML::TMX::Reader - Perl extension for reading TMX files SYNOPSIS
use XML::TMX::Reader; my $reader = XML::TMX::Reader->new( $filename ); $reader -> for_tu( sub { my $tu = shift; #blah blah blah }); @used_languages = $reader->languages; $reader->to_html() DESCRIPTION
This module provides a simple way for reading TMX files. METHODS
The following methods are available: "new" This method creates a new XML::TMX::Reader object. This process checks for the existence of the file and extracts some meta-information from the TMX header; my $reader = XML::TMX::Reader->new("my.tmx"); "ignore_markup" This method is used to set the flag to ignore (or not) markup inside translation unit segments. The default is to ignore those markup. If called without parameters, it sets the flag to ignore the markup. If you don't want to do that, use $reader->ignore_markup(0); "languages" This method returns the languages being used on the specified translation memory. Note that the module does not check for language code correctness or existence. "for_tu" Use "for_tu" to process all translation units from a TMX file. This version iterates for all tu (one at the time) The configuration hash is a reference to a Perl hash. At the moment these are valid options: "-verbose" Set this option to a true value and a counter of the number of processed translation units will be printed to stderr. "-output" | "output" Filename to output the changed TMX to. Note that if you use this option, your function should return a hash reference where keys are language names, and values their respective translation. "gen_tu" Write at most "gen_tu" TUs "proc_tu" Process at most "proc_tu" TUs "patt" Only process TU that match "patt". "-raw" Pass the XML directly to the method instead of parsing it. "-verbatim" Use segment contents verbatim, without any normalization. The function will receive two arguments: o a reference to a hash which maps: the language codes to the respective translation unit segment; a special key "-prop" that maps property names to properties; a special key "-note" that maps to a list of notes. o a reference to a hash which contains the attributes for those translation unit tag; If you want to process the TMX and return it again, your function should return an hash reference where keys are the languages, and values their respective translation. "to_html" Use this method to create a nice HTML file with the translation memories. Notice that this method is not finished yet, and relies on some images, on some specific locations. "for_tu2" deprecated. use "for_tu" SEE ALSO
XML::Writer(3), TMX Specification <http://www.lisa.org/tmx/tmx.htm> AUTHOR
Alberto Simo~es, <albie@alfarrabio.di.uminho.pt> Paulo Jorge Jesus Silva, <paulojjs@bragatel.pt> J.Joa~o Almeida, <jj@di.uminho.pt> COPYRIGHT AND LICENSE
Copyright 2003-2012 by Projecto Natura This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. perl v5.14.2 2012-06-05 XML::TMX::Reader(3pm)
Man Page