NAME
POSIX::Wide -- POSIX functions returning wide-char strings
SYNOPSIS
use POSIX::Wide;
print POSIX::Wide::strerror(2),"\n";
print POSIX::Wide::strftime("%a %d-%b\n",localtime());
DESCRIPTION
This is a few of the POSIX module functions adapted to return Perl wide-char strings instead of their usual locale charset byte strings.
EXPORTS
Nothing is exported by default, but each of the functions and the $ERRNO variable can be imported in the usual Exporter way. Eg.
use POSIX::Wide 'strftime', '$ERRNO';
There's no :all tag yet, as not sure if it would better import just the new funcs, or get everything from POSIX.
FUNCTIONS
$str = POSIX::Wide::localeconv ($format, ...)-
Return a hashref of locale information
{ decimal_point => ..., grouping => ... }String field values are wide chars. Non-string fields like
groupingor number fields likefrac_digitsare unchanged. $str = POSIX::Wide::perror ($message)-
Print
$messageand errno$!toSTDERR, with wide-chars for the errno string.$message: $!\n $str = POSIX::Wide::strerror ($errno)-
Return a descriptive string for a given
$errnonumber. $str = POSIX::Wide::strftime ($format, $sec, $min, $hour, $mday, $mon, $year, ...)-
Format a string of date-time parts.
$formatand the return are wide-char strings.The current implementation passes ASCII parts of
$format, including the "%" formatting directives, to strftime(). This means$formatcan include characters which might not exist in the locale charset. $num = $POSIX::Wide::ERRNO + 0$str = "$POSIX::Wide::ERRNO"-
A magic dual-value variable similar to
$!, giving the C libraryerrnoas a number or string. The string is wide-chars.
SEE ALSO
Glib::Utils, for a similar strerror.
HOME PAGE
http://user42.tuxfamily.org/i18n-langinfo-wide/index.html
LICENSE
I18N-Langinfo-Wide is Copyright 2008, 2009, 2010 Kevin Ryde
I18N-Langinfo-Wide is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3, or (at your option) any later version.
I18N-Langinfo-Wide is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with I18N-Langinfo-Wide. If not, see <http://www.gnu.org/licenses/>.