117 lines
5.5 KiB
HTML
117 lines
5.5 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="zh" dir="ltr" class="client-nojs" xmlns="http://www.w3.org/1999/xhtml" xml:lang="zh">
|
|
<head><meta http-equiv="x-ua-compatible" content="ie=edge">
|
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
|
<title>标准库头文件 <clocale></title>
|
|
<link rel="stylesheet" href="ext.css" />
|
|
<link rel="stylesheet" href="site_modules.css" />
|
|
</head>
|
|
<body class="mediawiki ltr sitedir-ltr ns-0 ns-subject page-cpp_header_clocale skin-cppreference2 action-view cpp-navbar">
|
|
<div id="cpp-content-base">
|
|
<div id="content"><a id="top"></a>
|
|
<h1 id="firstHeading" class="firstHeading"><span style="font-size:0.7em; line-height:130%">标准库头文件</span> <clocale></h1>
|
|
<div id="bodyContent">
|
|
<div id="contentSub"><span class="subpages">< <a href="cpp.html">cpp</a>‎ | <a href="cpp-header.html">header</a></span></div>
|
|
<div id="mw-content-text" lang="zh" dir="ltr" class="mw-content-ltr" xml:lang="zh">
|
|
<p>此头文件原作为 <code><b><locale.h></b></code> 存在于 C 标准库。</p>
|
|
<p>此头文件是<a href="cpp-locale.html">本地化</a>库的一部分。</p>
|
|
<table class="t-dsc-begin">
|
|
<tr>
|
|
<td colspan="2">
|
|
<h3><span class="mw-headline" id=".E7.B1.BB.E5.9E.8B">类型</span></h3>
|
|
</td>
|
|
</tr>
|
|
<tr class="t-dsc">
|
|
<td>
|
|
<div class="t-dsc-member-div">
|
|
<div><a href="cpp-locale-lconv.html"><span class="t-lines"><span>lconv</span></span></a></div>
|
|
</div>
|
|
</td>
|
|
<td><span class="t-lc"><a href="cpp-locale-localeconv.html">std::localeconv</a></span> 所返回的格式化细节<br />
|
|
<span class="t-mark">(类)</span></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="2">
|
|
<h3><span class="mw-headline" id=".E5.B8.B8.E9.87.8F">常量</span></h3>
|
|
</td>
|
|
</tr>
|
|
<tr class="t-dsc">
|
|
<td>
|
|
<div class="t-dsc-member-div">
|
|
<div><a href="cpp-types-NULL.html"><span class="t-lines"><span>NULL</span></span></a></div>
|
|
</div>
|
|
</td>
|
|
<td>实现定义的空指针常量<br />
|
|
<span class="t-mark">(宏常量)</span></td>
|
|
</tr>
|
|
<tr class="t-dsc">
|
|
<td>
|
|
<div class="t-dsc-member-div">
|
|
<div><a href="cpp-locale-LC_categories.html"><span class="t-lines"><span>LC_ALL</span><span>LC_COLLATE</span><span>LC_CTYPE</span><span>LC_MONETARY</span><span>LC_NUMERIC</span><span>LC_TIME</span></span></a></div>
|
|
</div>
|
|
</td>
|
|
<td><span class="t-lc"><a href="cpp-locale-setlocale.html">std::setlocale</a></span> 所用的本地环境类别<br />
|
|
<span class="t-mark">(宏常量)</span></td>
|
|
</tr>
|
|
<tr>
|
|
<td colspan="2">
|
|
<h3><span class="mw-headline" id=".E5.87.BD.E6.95.B0">函数</span></h3>
|
|
</td>
|
|
</tr>
|
|
<tr class="t-dsc">
|
|
<td>
|
|
<div class="t-dsc-member-div">
|
|
<div><a href="cpp-locale-setlocale.html"><span class="t-lines"><span>setlocale</span></span></a></div>
|
|
</div>
|
|
</td>
|
|
<td>获取和设置当前 C 本地环境<br />
|
|
<span class="t-mark">(函数)</span></td>
|
|
</tr>
|
|
<tr class="t-dsc">
|
|
<td>
|
|
<div class="t-dsc-member-div">
|
|
<div><a href="cpp-locale-localeconv.html"><span class="t-lines"><span>localeconv</span></span></a></div>
|
|
</div>
|
|
</td>
|
|
<td>查询当前本地环境的数值和货币格式化细节<br />
|
|
<span class="t-mark">(函数)</span></td>
|
|
</tr>
|
|
</table>
|
|
<h3><span class="mw-headline" id=".E6.A6.82.E8.A6.81">概要</span></h3>
|
|
<div dir="ltr" class="mw-geshi" style="text-align: left;">
|
|
<div class="cpp source-cpp">
|
|
<pre class="de1"><span class="kw1">namespace</span> std <span class="br0">{</span>
|
|
<span class="kw1">struct</span> lconv<span class="sy4">;</span>
|
|
|
|
<span class="kw4">char</span><span class="sy2">*</span> setlocale<span class="br0">(</span><span class="kw4">int</span> category, <span class="kw4">const</span> <span class="kw4">char</span><span class="sy2">*</span> locale<span class="br0">)</span><span class="sy4">;</span>
|
|
lconv<span class="sy2">*</span> localeconv<span class="br0">(</span><span class="br0">)</span><span class="sy4">;</span>
|
|
<span class="br0">}</span>
|
|
|
|
<span class="co2">#define NULL /* 见描述 */</span>
|
|
<span class="co2">#define LC_ALL /* 见描述 */</span>
|
|
<span class="co2">#define LC_COLLATE /* 见描述 */</span>
|
|
<span class="co2">#define LC_CTYPE /* 见描述 */</span>
|
|
<span class="co2">#define LC_MONETARY /* 见描述 */</span>
|
|
<span class="co2">#define LC_NUMERIC /* 见描述 */</span>
|
|
<span class="co2">#define LC_TIME /* 见描述 */</span></pre></div>
|
|
</div>
|
|
<h3><span class="mw-headline" id=".E6.B3.A8.E8.A7.A3">注解</span></h3>
|
|
<ul>
|
|
<li><span class="t-lc"><a href="cpp-types-NULL.html">NULL</a></span> 亦定义于下列头文件:
|
|
<ul>
|
|
<li><a href="cpp-header-cstring.html"><tt><cstring></tt></a></li>
|
|
<li><a href="cpp-header-ctime.html"><tt><ctime></tt></a></li>
|
|
<li><a href="cpp-header-cstddef.html"><tt><cstddef></tt></a></li>
|
|
<li><a href="cpp-header-cstdio.html"><tt><cstdio></tt></a></li>
|
|
<li><a href="cpp-header-cwchar.html"><tt><cwchar></tt></a></li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div class="visualClear"></div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</body>
|
|
</html>
|