package pomo

 Methods

PHP4 constructor.

Translation_Entry($args = array()
since 2.8.0
deprecated 5.4.0 Use __construct() instead.
see

Parameters

$args

__construct()

__construct(array $args = array()

Parameters

$args

array

{ Arguments array, supports the following keys:

@type string $singular            The string to translate, if omitted an
                                  empty entry will be created.
@type string $plural              The plural form of the string, setting
                                  this will set `$is_plural` to true.
@type array  $translations        Translations of the string and possibly
                                  its plural forms.
@type string $context             A string differentiating two equal strings
                                  used in different contexts.
@type string $translator_comments Comments left by translators.
@type string $extracted_comments  Comments left by developers.
@type array  $references          Places in the code this string is used, in
                                  relative_to_root_path/file.php:linenum form.
@type array  $flags               Flags like php-format.

}

Generates a unique key for this entry.

key() : string | false
since 2.8.0

Returns

stringfalseThe key or false if the entry is null.

Merges another translation entry with the current one.

merge_with(\Translation_Entry $other) 
since 2.8.0

Parameters

$other

\Translation_Entry

Other translation entry.

 Properties

 

$context

$context 

Default

null
 

$extracted_comments

$extracted_comments 

Default

''
 

$flags

$flags 

Default

array()
 

Whether the entry contains a string and its plural form, default is false.

$is_plural : boolean

Default

false
 

$plural

$plural 

Default

null
 

$references

$references 

Default

array()
 

$singular

$singular 

Default

null
 

$translations

$translations 

Default

array()
 

$translator_comments

$translator_comments 

Default

''