⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 wchar.h.html

📁 IEEE 1003.1-2003, Single Unix Specification v3
💻 HTML
📖 第 1 页 / 共 2 页
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><meta name="generator" content="HTML Tidy, see www.w3.org"><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"><link type="text/css" rel="stylesheet" href="style.css"><!-- Generated by The Open Group's rhtm tool v1.2.1 --><!-- Copyright (c) 2001-2003 The Open Group, All Rights Reserved --><title>&lt;wchar.h&gt;</title></head><body bgcolor="white"><script type="text/javascript" language="JavaScript" src="../jscript/codes.js"></script><basefont size="3"> <a name="&lt;wchar.h&gt;"></a> <a name="tag_13_83"></a><!-- &lt;wchar.h&gt; --> <!--header start--><center><font size="2">The Open Group Base Specifications Issue 6<br>IEEE Std 1003.1, 2003 Edition<br>Copyright &copy; 2001-2003 The IEEE and The Open Group, All Rights reserved.</font></center><!--header end--><hr size="2" noshade><h4><a name="tag_13_83_01"></a>NAME</h4><blockquote>wchar.h - wide-character handling</blockquote><h4><a name="tag_13_83_02"></a>SYNOPSIS</h4><blockquote class="synopsis"><p><tt>#include &lt;wchar.h&gt;</tt></p></blockquote><h4><a name="tag_13_83_03"></a>DESCRIPTION</h4><blockquote><div class="box"><sup>[<a href="javascript:open_code('CX')">CX</a>]</sup> <img src="../images/opt-start.gif" alt="[Option Start]"border="0"> Some of the functionality described on this reference page extends the ISO&nbsp;C standard. Applications shall definethe appropriate feature test macro (see the System Interfaces volume of IEEE&nbsp;Std&nbsp;1003.1-2001, <a href="../functions/xsh_chap02_02.html">Section 2.2, The Compilation Environment</a>) to enable the visibility of these symbols in thisheader. <img src="../images/opt-end.gif" alt="[Option End]" border="0"></div><p>The <i>&lt;wchar.h&gt;</i> header shall define the following types:</p><dl compact><dt><b>wchar_t</b></dt><dd>As described in <a href="stddef.h.html"><i>&lt;stddef.h&gt;</i></a> .</dd><dt><b>wint_t</b></dt><dd>An integer type capable of storing any valid value of <b>wchar_t</b> or WEOF.</dd><dt><b>wctype_t</b></dt><dd><sup>[<a href="javascript:open_code('XSI')">XSI</a>]</sup> <img src="../images/opt-start.gif" alt="[Option Start]" border="0">A scalar type of a data object that can hold values which represent locale-specific character classification. <img src="../images/opt-end.gif" alt="[Option End]" border="0"></dd><dt><b>mbstate_t</b></dt><dd>An object type other than an array type that can hold the conversion state information necessary to convert between sequencesof (possibly multi-byte) characters and wide characters. <sup>[<a href="javascript:open_code('XSI')">XSI</a>]</sup> <img src="../images/opt-start.gif" alt="[Option Start]" border="0"> &nbsp;If a codeset is being used such that an <b>mbstate_t</b> needs topreserve more than 2 levels of reserved state, the results are unspecified. <img src="../images/opt-end.gif" alt="[Option End]"border="0"></dd><dt><b>FILE</b></dt><dd><sup>[<a href="javascript:open_code('XSI')">XSI</a>]</sup> <img src="../images/opt-start.gif" alt="[Option Start]" border="0">As described in <a href="stdio.h.html"><i>&lt;stdio.h&gt;</i></a> . <img src="../images/opt-end.gif" alt="[Option End]" border="0"></dd><dt><b>size_t</b></dt><dd>As described in <a href="stddef.h.html"><i>&lt;stddef.h&gt;</i></a> .</dd><dt><b>va_list</b></dt><dd><sup>[<a href="javascript:open_code('XSI')">XSI</a>]</sup> <img src="../images/opt-start.gif" alt="[Option Start]" border="0">As described in <a href="stdarg.h.html"><i>&lt;stdarg.h&gt;</i></a> . <img src="../images/opt-end.gif" alt="[Option End]" border="0"></dd></dl><p>The implementation shall support one or more programming environments in which the width of <b>wint_t</b> is no greater than thewidth of type <b>long</b>. The names of these programming environments can be obtained using the <a href="../functions/confstr.html"><i>confstr</i>()</a> function or the <a href="../utilities/getconf.html"><i>getconf</i></a>utility.</p><p>The following shall be declared as functions and may also be defined as macros. Function prototypes shall be provided.</p><pre><tt>wint_t        btowc(int);wint_t        fgetwc(FILE *);wchar_t      *fgetws(wchar_t *restrict, int, FILE *restrict);wint_t        fputwc(wchar_t, FILE *);int           fputws(const wchar_t *restrict, FILE *restrict);int           fwide(FILE *, int);int           fwprintf(FILE *restrict, const wchar_t *restrict, ...);int           fwscanf(FILE *restrict, const wchar_t *restrict, ...);wint_t        getwc(FILE *);wint_t        getwchar(void);<sup>[<a href="javascript:open_code('XSI')">XSI</a>]</sup><img src="../images/opt-start.gif" alt="[Option Start]" border="0">int           iswalnum(wint_t);int           iswalpha(wint_t);int           iswcntrl(wint_t);int           iswctype(wint_t, wctype_t);int           iswdigit(wint_t);int           iswgraph(wint_t);int           iswlower(wint_t);int           iswprint(wint_t);int           iswpunct(wint_t);int           iswspace(wint_t);int           iswupper(wint_t);int           iswxdigit(wint_t);<img src="../images/opt-end.gif" alt="[Option End]" border="0">size_t        mbrlen(const char *restrict, size_t, mbstate_t *restrict);size_t        mbrtowc(wchar_t *restrict, const char *restrict, size_t,                  mbstate_t *restrict);int           mbsinit(const mbstate_t *);size_t        mbsrtowcs(wchar_t *restrict, const char **restrict, size_t,                  mbstate_t *restrict);wint_t        putwc(wchar_t, FILE *);wint_t        putwchar(wchar_t);int           swprintf(wchar_t *restrict, size_t,                  const wchar_t *restrict, ...);int           swscanf(const wchar_t *restrict,                  const wchar_t *restrict, ...);<sup>[<a href="javascript:open_code('XSI')">XSI</a>]</sup><img src="../images/opt-start.gif" alt="[Option Start]" border="0">wint_t        towlower(wint_t);wint_t        towupper(wint_t);<img src="../images/opt-end.gif" alt="[Option End]" border="0">wint_t        ungetwc(wint_t, FILE *);int           vfwprintf(FILE *restrict, const wchar_t *restrict, va_list);int           vfwscanf(FILE *restrict, const wchar_t *restrict, va_list);int           vwprintf(const wchar_t *restrict, va_list);int           vswprintf(wchar_t *restrict, size_t,                  const wchar_t *restrict, va_list);int           vswscanf(const wchar_t *restrict, const wchar_t *restrict,                  va_list);int           vwscanf(const wchar_t *restrict, va_list);size_t        wcrtomb(char *restrict, wchar_t, mbstate_t *restrict);wchar_t      *wcscat(wchar_t *restrict, const wchar_t *restrict);wchar_t      *wcschr(const wchar_t *, wchar_t);int           wcscmp(const wchar_t *, const wchar_t *);int           wcscoll(const wchar_t *, const wchar_t *);wchar_t      *wcscpy(wchar_t *restrict, const wchar_t *restrict);size_t        wcscspn(const wchar_t *, const wchar_t *);size_t        wcsftime(wchar_t *restrict, size_t,                  const wchar_t *restrict, const struct tm *restrict);size_t        wcslen(const wchar_t *);wchar_t      *wcsncat(wchar_t *restrict, const wchar_t *restrict, size_t);int           wcsncmp(const wchar_t *, const wchar_t *, size_t);wchar_t      *wcsncpy(wchar_t *restrict, const wchar_t *restrict, size_t);wchar_t      *wcspbrk(const wchar_t *, const wchar_t *);wchar_t      *wcsrchr(const wchar_t *, wchar_t);size_t        wcsrtombs(char *restrict, const wchar_t **restrict,                  size_t, mbstate_t *restrict);size_t        wcsspn(const wchar_t *, const wchar_t *);wchar_t      *wcsstr(const wchar_t *restrict, const wchar_t *restrict);double        wcstod(const wchar_t *restrict, wchar_t **restrict);float         wcstof(const wchar_t *restrict, wchar_t **restrict);wchar_t      *wcstok(wchar_t *restrict, const wchar_t *restrict,                  wchar_t **restrict);long          wcstol(const wchar_t *restrict, wchar_t **restrict, int);long double   wcstold(const wchar_t *restrict, wchar_t **restrict);long long     wcstoll(const wchar_t *restrict, wchar_t **restrict, int);unsigned long wcstoul(const wchar_t *restrict, wchar_t **restrict, int);unsigned long long              wcstoull(const wchar_t *restrict, wchar_t **restrict, int);<sup>[<a href="javascript:open_code('XSI')">XSI</a>]</sup><img src="../images/opt-start.gif" alt="[Option Start]" border="0">wchar_t      *wcswcs(const wchar_t *, const wchar_t *);int           wcswidth(const wchar_t *, size_t);<img src="../images/opt-end.gif" alt="[Option End]" border="0">size_t        wcsxfrm(wchar_t *restrict, const wchar_t *restrict, size_t);int           wctob(wint_t);<sup>[<a href="javascript:open_code('XSI')">XSI</a>]</sup><img src="../images/opt-start.gif" alt="[Option Start]" border="0">wctype_t      wctype(const char *);int           wcwidth(wchar_t);<img src="../images/opt-end.gif" alt="[Option End]" border="0">wchar_t      *wmemchr(const wchar_t *, wchar_t, size_t);

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -