| 1 | package HTML::FormHandler::I18N; | ||||||||||
| 2 | # ABSTRACT: internationalization | ||||||||||
| 3 | 147 | $HTML::FormHandler::I18N::VERSION = '0.410001'; | |||||||||
| 4 | 147 | ▶ | use strict; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 5 | 147 | ▶ | use warnings; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 6 | 147 | ▶ | use base ('Locale::Maketext'); | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 7 | 147 | ▶ | use Try::Tiny; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 8 | |||||||||||
| 9 | sub maketext { | ||||||||||
| 10 | 880 | ▶ | my ( $lh, @message ) = @_; | ||||||||
|
Subroutine
maketext: called CC=3 SCAR=11.4
Pod
undocumented
| |||||||||||
| 11 | 880 | ▶ | return '' unless scalar @message; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 12 | 880 | ▶ | return '' unless defined $message[0]; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 13 | 880 | my $out; | |||||||||
| 14 | try { | ||||||||||
| 15 | 880 | ▶ | $out = $lh->SUPER::maketext(@message); | ||||||||
|
Subroutine
__ANON__: called CC=1 SCAR=0.0
| |||||||||||
| 16 | } | ||||||||||
| 17 | catch { | ||||||||||
| 18 | 0 | ▶ | die "Unable to do maketext on: " . $message[0] . | ||||||||
|
Subroutine
__ANON__: not called CC=1 SCAR=6.9
| |||||||||||
| 19 | "\nIf the message contains brackets you may need to escape them with a tilde."; | ||||||||||
| 20 | 880 | }; | |||||||||
| 21 | 880 | return $out; | |||||||||
| 22 | } | ||||||||||
| 23 | |||||||||||
| 24 | 147 | 1; | |||||||||
| 25 | |||||||||||
| 26 | __END__ | ||||||||||
| 27 | |||||||||||
| 28 | =pod | ||||||||||
| 29 | |||||||||||
| 30 | =encoding UTF-8 | ||||||||||
| 31 | |||||||||||
| 32 | =head1 NAME | ||||||||||
| 33 | |||||||||||
| 34 | HTML::FormHandler::I18N - internationalization | ||||||||||
| 35 | |||||||||||
| 36 | =head1 VERSION | ||||||||||
| 37 | |||||||||||
| 38 | version 0.410001 | ||||||||||
| 39 | |||||||||||
| 40 | =head1 AUTHOR | ||||||||||
| 41 | |||||||||||
| 42 | FormHandler Contributors - see HTML::FormHandler | ||||||||||
| 43 | |||||||||||
| 44 | =head1 COPYRIGHT AND LICENSE | ||||||||||
| 45 | |||||||||||
| 46 | This software is copyright (c) 2017 by Gerda Shank. | ||||||||||
| 47 | |||||||||||
| 48 | This is free software; you can redistribute it and/or modify it under | ||||||||||
| 49 | the same terms as the Perl 5 programming language system itself. | ||||||||||
| 50 | |||||||||||
| 51 | =cut | ||||||||||