NAME Locale::TextDomain::OO::Extract::Role::File - Gettext file related stuff
$Id: File.pm 683 2017-08-22 18:41:42Z steffenw $
$HeadURL: svn+ssh://steffenw@svn.code.sf.net/p/perl-gettext-oo/code/extract/trunk/lib/Locale/TextDomain/OO/Extract/Role/File.pm $
VERSION
2.007
DESCRIPTION
Role for gettext file related stuff.
SYNOPSIS
with 'Locale::TextDomain::OO::Extract::Role::File';
SUBROUTINES/METHODS
method category
Set/get the default category.
method domain
Set/get the default domain.
method project
Set/get the default project.
method filename
Set/get the filename for reference.
method lexicon_ref
Set/get the extracted data as lexicon data structure.
method is_maketext_format_gettext
Set/get a boolean if the lexicon has %1 or [_1] for maketext placeholders.
method clear
Clears category, domain. project, category_stack, domain_stack and filename. That is important before extract the next file.
method add_message
$extractor->add_message({
category => 'my category', # or q{} or undef
domain => 'my domain', # or q{} or undef
reference => 'dir/file.ext:123',
automatic => 'my automatic comment',
msgctxt => 'my context' # or q{} or undef
msgid => 'my singular',
msgid_plural => 'my plural', # or q{} or undef
});
EXAMPLE
Inside of this distribution is a directory named example. Run this *.pl files.
DIAGNOSTICS
none
CONFIGURATION AND ENVIRONMENT
none
DEPENDENCIES
Locale::TextDomain::OO::Util::JoinSplitLexiconKeys
Locale::Utils::PlaceholderMaketext
INCOMPATIBILITIES
not known
BUGS AND LIMITATIONS
none
SEE ALSO
AUTHOR
Steffen Winkler
LICENSE AND COPYRIGHT
Copyright (c) 2014 - 2017, Steffen Winkler <steffenw at cpan.org>
. All rights reserved.
This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.