05 Jul 2022 04:54:13 UTC
- Distribution: Text-PO
- Module version: v0.1.0
- Source (raw)
- Browse (raw)
- How to Contribute
- KwaliteeBus factor: 1
- 45.96% Coverage
- License: perl_5
- Perl: v5.14.0
- Download (97.53KB)
- MetaCPAN Explorer
- Subscribe to distribution
- This version
- Latest version++ed by:1 non-PAUSE user
- Jacques Deguest (firstname.lastname@example.org)
- SEE ALSO
- COPYRIGHT & LICENSE
Text::PO::Element - PO Element
use Text::PO::Element; my $po = Text::PO::Element->new; $po->debug( 2 ); $po->dump;
This is the class for PO elements.
Create a new Text::PO::Element object acting as an accessor.
Text::PO::Elementobject has the following fields :
The localisation id
The localised string
The optional localised string in plural
The optional context.
The fuzzy flag set when the entry has been created but not yet translated
The optional comment that can be added to provide some explanations to the translator
The optional comment added automatically
An optional set of flags, stored as an array reference
Whether this has a plural form
The character encoding
The file in which this l10n string was found. This is set when automatic parsing was executed
The line at which this l10n was found. This is set when automatic parsing was executed
An optional boolean value provided if this element represents a meta information
Add an auto comment
Add a comment
Add a msgid
Add a plural version of a msgid
Add a msgstr
Add a reference, which is a file and line number
Set or return the auto_comment field
Set or return the comment field
Set or return the context field
Remove the element from the list of elements in Text::PO
Return the element as a string formatted for a po file.
Set or return the flags as array reference
Return the value of msgid as a string
Set or gets the flag that this element represents the meta information for this PO (a.k.a portable object) file.
Meta information for a po file is stored in a unique msgid whose value is null.
Text::PO::Elementobject, it merge its content with our element object.
The merge will not overwrite existing fields.
It returns the current object
Set or return the msgstr as a value without surrounding quote and without escaping.
This returns the msgid escaped and with surrounding quotes, suitable for "dump"
msgidproperty as a string when it has plural implemented.
This returns the msgstr escaped and with surrounding quotes, suitable for "dump"
Sets or gets the Text::PO object associated with this element. Best that you know what you are doing if you change this.
Given an array reference or a string separated by ':', it sets the file and line number for this element object.
Given a text, it returns an array reference of lines wrapped
Given a string, it returns an array reference of lines. This is called by "wrap"
Jacques Deguest <email@example.com>
Copyright (c) 2020-2021 DEGUEST Pte. Ltd.
You can use, copy, modify and redistribute this package and associated files under the same terms as Perl itself.
|s||Focus search bar|
|?||Bring up this help dialog|
|g p||Go to pull requests|
|g i||go to github issues (only if github is preferred repository)|
|g a||Go to author|
|g c||Go to changes|
|g i||Go to issues|
|g d||Go to dist|
|g r||Go to repository/SCM|
|g s||Go to source|
|g b||Go to file browse|