423 lines
15 KiB
Plaintext
423 lines
15 KiB
Plaintext
# C++ Plus NLS Util language map for cppp-reiconv.
|
||
# zh_CN
|
||
|
||
'''
|
||
/* Copyright (C) 1999-2023 Free Software Foundation, Inc.
|
||
This file is part of the cppp-reiconv library.
|
||
|
||
The cppp-reiconv library is free software; you can redistribute it
|
||
and/or modify it under the terms of the GNU Lesser General Public
|
||
License as published by the Free Software Foundation; either version 3
|
||
of the License, or (at your option) any later version.
|
||
|
||
The cppp-reiconv library 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
|
||
Lesser General Public License for more details.
|
||
|
||
You should have received a copy of the GNU Lesser General Public
|
||
License along with the cppp-reiconv library; see the file COPYING.
|
||
If not, see <https://www.gnu.org/licenses/>. */
|
||
'''
|
||
/* 版权所有 (C) 1999-2023 Free Software Foundation, Inc.
|
||
本文件是 cppp-reiconv 库的一部分。
|
||
|
||
cppp-reiconv 库是自由软件,您可以在自由软件基金会发布的 GNU Lesser General Public
|
||
License 版本 3 或者(根据您的选择)任何以后的版本下重新分发和/或修改它。
|
||
|
||
cppp-reiconv 库被分发,希望它对您有用,但没有任何担保;甚至没有暗示的担保
|
||
商业性和特定目的适用性的担保。请参阅 GNU Lesser General Public License 获取更多详细信息。
|
||
|
||
您应该已经收到了 GNU Lesser General Public License 的副本
|
||
与 cppp-reiconv 库一起;请参阅 COPYING 文件。
|
||
如果没有,请参阅 https://www.gnu.org/licenses/ 。 */
|
||
'''
|
||
|
||
'''
|
||
/* When installed, this file is called "cppp/reiconv.hpp". */
|
||
'''
|
||
/* 安装之后,这个文件叫做 “cppp/reiconv.hpp”。 */
|
||
'''
|
||
|
||
'''
|
||
/* Use UTF-8 to decode this file. */
|
||
'''
|
||
/* 使用 UTF-8 解析这个文件 */
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Version infomation. (major<<8) + minor
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 版本信息。 算法:(major<<8) + minor
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @typedef void*
|
||
* @brief Identifier for conversion method from one codeset to another.
|
||
*/
|
||
'''
|
||
/**
|
||
* @typedef void*
|
||
* @brief 从一个字符集到另一个字符集中的转换方法的标识符。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Allocates descriptor for code conversion from encoding 'fromcode' to encoding 'tocode'.
|
||
* @param tocode Target encoding.
|
||
* @param fromcode From encoding.
|
||
* @return Allocated iconv conversation buffer's pointer.
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 为从编码 “fromcode” 到编码 “tocode” 的编码转换分配描述符。
|
||
* @param tocode 目标编码。
|
||
* @param fromcode 原编码。
|
||
* @return 分配的 iconv 描述符。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Allocates descriptor for code conversion from codepage 'tocode_cp' to codepage 'fromcode_cp'.
|
||
* @param tocode_cp Target codepage.
|
||
* @param fromcode_cp From codepage.
|
||
* @param strict Strict mode, if false, will ignore the invalid characters.
|
||
* @note Some encoding may don't have codepage.
|
||
* @return Allocated iconv conversation buffer's pointer.
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 为从代码页 “fromcode_cp” 到代码页 “tocode_cp” 的编码转换分配描述符。
|
||
* @param tocode_cp Target codepage.
|
||
* @param fromcode_cp From codepage.
|
||
* @param strict Strict mode, if false, will ignore the invalid characters.
|
||
* @note Some encoding may don't have codepage.
|
||
* @return Allocated iconv conversation buffer's pointer.
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Converts, using conversion descriptor 'cd', at most '*inbytesleft' bytes starting at '*inbuf', writing at
|
||
* most '*outbytesleft' bytes starting at '*outbuf'.
|
||
* @attention Decrements '*inbytesleft' and increments '*inbuf' by the same amount.
|
||
* @attention Decrements '*outbytesleft' and increments '*outbuf' by the same amount.
|
||
* @param cd Conversion descriptor.
|
||
* @param inbuf Input buffer.
|
||
* @param inbytesleft Input bytes left.
|
||
* @param outbuf Output buffer.
|
||
* @param outbytesleft Output bytes left.
|
||
* @return Number of converted characters (excluding terminators, -1 means error).
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 使用转换描述符 “cd”,将最多 “*inbytesleft” 字节从 “*inbuf” 开始转换,并将最多 “*outbytesleft” 字节写入
|
||
* “*outbuf” 。
|
||
* @attention 将 “*inbytesleft” 减少相同的数量,并将 “*inbuf” 增加相同的数量。
|
||
* @attention 将 “*outbytesleft” 减少相同的数量,并将 “*outbuf” 增加相同的数量。
|
||
* @param cd 转换描述符。
|
||
* @param inbuf 输入缓冲区。
|
||
* @param inbytesleft 剩余输入字节。
|
||
* @param outbuf 输出缓冲区。
|
||
* @param outbytesleft 剩余输出字节。
|
||
* @return 转换的字符数量(不包括终止符,-1 表示错误)。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Frees resources allocated for conversion descriptor 'cd'.
|
||
* @param cd Conversion descriptor you want to close.
|
||
* @return Operation status. (-1 means error, 0 means success).
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 释放为转换描述符 “cd” 分配的资源。
|
||
* @param cd 您想要释放的 iconv 转换描述符。
|
||
* @return 操作状态。(-1 表示错误,0 表示成功)。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Control of attributes.
|
||
* @param cd Conversion descriptor.
|
||
* @param request Attribute request id.
|
||
* @param argument Attribute argument.
|
||
* @return Operation status (>=0 means success, <0 means error).
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 设置描述符的属性
|
||
* @param cd 转换描述符。
|
||
* @param request 属性请求 ID。
|
||
* @param argument 属性的值。
|
||
* @return 操作状态(>=0 表示成功,<0 表示错误)。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @typedef void (*) (unsigned int, void*)
|
||
* @brief Hook performed after every successful conversion of a Unicode character.
|
||
*/
|
||
'''
|
||
/**
|
||
* @typedef void (*) (unsigned int, void*)
|
||
* @brief 在每次成功转换 Unicode 字符之后执行的钩子函数。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Set of hooks.
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 钩子函数集。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Fallback function. Invoked when a small number of bytes could not be
|
||
* converted to a Unicode character. This function should process all
|
||
* bytes from inbuf and may produce replacement Unicode characters by calling
|
||
* the write_replacement callback repeatedly.
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 回调函数。当少量字节无法转换为 Unicode 字符时调用。
|
||
* 此函数应处理 “inbuf” 中的所有字节,并通过多次调用 “write_replacement” 回调函数生成替换的 Unicode 字符。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Fallback function. Invoked when a Unicode character could not be converted
|
||
* to the target encoding. This function should process the character and
|
||
* may produce replacement bytes (in the target encoding) by calling the
|
||
* write_replacement callback repeatedly.
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 回调函数。在无法将 Unicode 字符转换为目标编码时调用。
|
||
* 此函数应处理字符,并可通过重复调用 “write_replacement” 回调来生成替代字节(使用目标编码)。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Set of fallbacks.
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 回调函数集。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Surfaces. The concept of surfaces is described in the 'recode' manual.
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief Surfaces. “Surfaces” 是在 “recode” 手册中描述的概念。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief In EBCDIC encodings, 0x15 (which encodes the "newline function", see the
|
||
* Unicode standard, chapter 5) maps to U+000A instead of U+0085. This is
|
||
* for interoperability with C programs and Unix environments on z/OS.
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 在 EBCDIC 编码中,0x15(用于编码“换行符功能”,参见 Unicode 标准第 5 章)将映射为 U+000A 而不是 U+0085 。
|
||
* 这是为了在 z/OS 上与 C 程序和 Unix 环境实现互操作性。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Request for iconvctl.
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief “iconvctl” 的 “request”.
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Listing of locale independent encodings.
|
||
* @param do_one One encoding fallback function.
|
||
* @param data Data.
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 列出与区域设置无关的编码方式。
|
||
* @param do_one 一个编码回退函数。
|
||
* @param data 数据。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Converts an entire string from one encoding to another, using iconv. Easier to use than iconv() itself.
|
||
* @note This function does not treat zero characters specially.
|
||
* @param cd Conversion descriptor.
|
||
* @param start Source string start pointer.
|
||
* @param end Source string end pointer.
|
||
* @param resultp Result memory pointer.
|
||
* @param lengthp Pointer to a variable that stores the length of the result.
|
||
* @return Return 0 if successful, otherwise return errno and errno set. Particular errno values are EILSEQ and ENOMEM.
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 使用 iconv 将整个字符串从一种编码转换为另一种编码。比直接使用 iconv() 函数更简单。
|
||
* @note 该函数不特殊处理 '\0' 字符。
|
||
* @param cd 转换描述符。
|
||
* @param start 源字符串起始指针。
|
||
* @param end 源字符串结束指针。
|
||
* @param resultp 结果内存指针。
|
||
* @param lengthp 指向存储结果长度的变量的指针。
|
||
* @return 如果成功,返回 0 ,否则返回 errno 并设置 errno 。特定的 errno 值包括 EILSEQ 和 ENOMEM 。
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Converts an entire string from one encoding to another,
|
||
* and supports autodetect encodings on input.
|
||
*
|
||
* @note Converts a memory region given in encoding FROMCODE to a new memory
|
||
* region in encoding TOCODE. FROMCODE and TOCODE are as for iconv_open(3),
|
||
* except that FROMCODE may be one of the values.
|
||
*
|
||
* @note "autodetect_utf8" supports ISO-8859-1 and UTF-8
|
||
* @note "autodetect_jp" supports EUC-JP, ISO-2022-JP-2 and SHIFT_JIS
|
||
* @note "autodetect_kr" supports EUC-KR and ISO-2022-KR
|
||
* @note The input is in the memory region between start (inclusive) and end
|
||
* (exclusive). If resultp is not NULL, the output string is stored in
|
||
* *resultp; malloc/realloc is used to allocate the result.
|
||
*
|
||
* @note This function does not treat zero characters specially.
|
||
* @param tocode Target encoding.
|
||
* @param fromcode From encoding.
|
||
* @param start Source string start pointer.
|
||
* @param end Source string end pointer.
|
||
* @param resultp Result memory pointer.
|
||
* @param lengthp Pointer to a variable that stores the length of the result.
|
||
* @return Return 0 if successful, otherwise return errno and errno set. Particular errno values: EILSEQ and ENOMEM.
|
||
*
|
||
* @example
|
||
* const char* s = ...;
|
||
* char* result = NULL;
|
||
* if (iconv_string("UCS-4-INTERNAL", "GBK",
|
||
* s, s+strlen(s)+1, &result, NULL) != 0)
|
||
* perror("iconv_string");
|
||
*
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 将整个字符串从一种编码转换为另一种编码,并支持自动检测输入编码。
|
||
*
|
||
* @note 将以编码 FROMCODE 给出的内存区域转换为以编码 TOCODE 给出的新内存区域。 FROMCODE 和 TOCODE 与 iconv_open(3) 中的参数相同,但 FROMCODE 可能是以下值之一。
|
||
*
|
||
* @note "autodetect_utf8" 支持 ISO-8859-1 和 UTF-8
|
||
* @note "autodetect_jp" 支持 EUC-JP 、 ISO-2022-JP-2和 SHIFT_JIS
|
||
* @note "autodetect_kr" 支持 EUC-KR 和 ISO-2022-KR
|
||
* @note 输入位于 start (包含)和 end (不包含)之间的内存区域。如果 resultp 不为 NULL ,则输出字符串存储在 *resultp 中; malloc/realloc 用于分配结果。
|
||
*
|
||
* @note 该函数不特殊处理零字符。
|
||
* @param tocode 目标编码。
|
||
* @param fromcode 源编码。
|
||
* @param start 源字符串起始指针。
|
||
* @param end 源字符串结束指针。
|
||
* @param resultp 结果内存指针。
|
||
* @param lengthp 指向存储结果长度的变量的指针。
|
||
* @return 如果成功,返回0;否则返回 errno 并设置 errno 。特定的 errno 值包括 EILSEQ 和 ENOMEM 。
|
||
*
|
||
* @example
|
||
* const char* s = ...;
|
||
* char* result = NULL;
|
||
* if (iconv_string("UCS-4-INTERNAL", "GBK",
|
||
* s, s+strlen(s)+1, &result, NULL) != 0)
|
||
* perror("iconv_string");
|
||
*
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Converts an entire string from one encoding to another.
|
||
* @note This function does not treat zero characters specially.
|
||
* @param tocode_cp Target encoding codepage.
|
||
* @param fromcode_cp From encoding codepage.
|
||
* @param start Source string start pointer.
|
||
* @param end Source string end pointer.
|
||
* @param resultp Result memory pointer.
|
||
* @param lengthp Pointer to a variable that stores the length of the result.
|
||
* @param strict Strict mode, if false, will ignore the invalid characters.
|
||
* @return Return 0 if successful, otherwise return errno and errno set. Particular errno values: EILSEQ and ENOMEM.
|
||
*
|
||
* @example
|
||
* const char* s = ...;
|
||
* char* result = NULL;
|
||
* if (iconv_string(65001, 936,
|
||
* s, s+strlen(s)+1, &result, NULL) != 0)
|
||
* perror("iconv_string");
|
||
*
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 将整个字符串从一种编码转换为另一种编码。
|
||
* @note 该函数不特殊处理零字符。
|
||
* @param tocode_cp 目标编码页。
|
||
* @param fromcode_cp 源编码页。
|
||
* @param start 源字符串起始指针。
|
||
* @param end 源字符串结束指针。
|
||
* @param resultp 结果内存指针。
|
||
* @param lengthp 指向存储结果长度的变量的指针。
|
||
* @param strict 严格模式,如果为 false ,将忽略无效字符。
|
||
* @return 如果成功,返回 0 ;否则返回 errno 并设置 errno 。特定的 errno 值包括 EILSEQ 和 ENOMEM 。
|
||
*
|
||
* @example
|
||
* const char* s = ...;
|
||
* char* result = NULL;
|
||
* if (iconv_string(65001, 936,
|
||
* s, s+strlen(s)+1, &result, NULL) != 0)
|
||
* perror("iconv_string");
|
||
*
|
||
*/
|
||
'''
|
||
|
||
'''
|
||
/**
|
||
* @brief Encode source string to another encoding.
|
||
* @param from From encoding.
|
||
* @param to Target encoding.
|
||
* @param data Input string data.
|
||
* @param ignore Ignore invalid characters.
|
||
* @throw int: when conversation error, throw the 'errno', you can catch the errno for more infomation.
|
||
*/
|
||
'''
|
||
/**
|
||
* @brief 将源字符串编码为另一种编码方式。
|
||
* @param from 源编码。
|
||
* @param to 目标编码。
|
||
* @param data 输入字符串数据。
|
||
* @param ignore 忽略无效字符。
|
||
* @throw int:当转换错误时,抛出 “errno” ,您可以捕获 errno 以获取更多信息。
|
||
*/
|
||
'''
|