OSDN Git Service

91b552b212756bc3cb1c872c4855a22f6c9c1f1e
[linuxjm/LDP_man-pages.git] / draft / man3 / wcpncpy.3
1 .\" Copyright (c) Bruno Haible <haible@clisp.cons.org>
2 .\"
3 .\" %%%LICENSE_START(GPLv2+_DOC_ONEPARA)
4 .\" This is free documentation; you can redistribute it and/or
5 .\" modify it under the terms of the GNU General Public License as
6 .\" published by the Free Software Foundation; either version 2 of
7 .\" the License, or (at your option) any later version.
8 .\" %%%LICENSE_END
9 .\"
10 .\" References consulted:
11 .\"   GNU glibc-2 source code and manual
12 .\"   Dinkumware C library reference http://www.dinkumware.com/
13 .\"   OpenGroup's Single UNIX specification http://www.UNIX-systems.org/online.html
14 .\"
15 .\"*******************************************************************
16 .\"
17 .\" This file was generated with po4a. Translate the source file.
18 .\"
19 .\"*******************************************************************
20 .TH WCPNCPY 3 2011\-10\-01 GNU "Linux Programmer's Manual"
21 .SH 名前
22 wcpncpy \- 固定長のワイド文字文字列をコピーし、その末尾を指すポインタを返す
23 .SH 書式
24 .nf
25 \fB#include <wchar.h>\fP
26 .sp
27 \fBwchar_t *wcpncpy(wchar_t *\fP\fIdest\fP\fB, const wchar_t *\fP\fIsrc\fP\fB, size_t \fP\fIn\fP\fB);\fP
28 .fi
29 .sp
30 .in -4n
31 glibc 向けの機能検査マクロの要件 (\fBfeature_test_macros\fP(7)  参照):
32 .in
33 .sp
34 \fBwcpncpy\fP():
35 .PD 0
36 .ad l
37 .RS 4
38 .TP  4
39 glibc 2.10 以降:
40 _XOPEN_SOURCE\ >=\ 700 || _POSIX_C_SOURCE\ >=\ 200809L
41 .TP 
42 glibc 2.10 より前:
43 _GNU_SOURCE
44 .RE
45 .ad
46 .PD
47 .SH 説明
48 \fBwcpncpy\fP()  関数は、 \fBstpncpy\fP(3)  関数に対応するワイド文字関数である。 この関数は、\fIsrc\fP
49 が指すワイド文字文字列から \fIdest\fP が指す ワイド文字文字列に、終端の NULL ワイド文字 (L\(aq\e0\(aq) を含めて 最大
50 \fIn\fP 文字をコピーする。 ちょうど \fIn\fP 個のワイド文字が \fIdest\fP にコピーされる。 つまり、\fIwcslen(src)\fP の長さが
51 \fIn\fP より小さければ、 \fIdest\fP が指す配列中の残りのワイド文字は L\(aq\e0\(aq 文字で埋められる。 \fIwcslen(src)\fP
52 の長さが \fIn\fP 以上ならば、\fIdest\fP が指す 文字列は L\(aq\e0\(aq で終端されない。
53 .PP
54 これらの文字列は重なっていてはならない。
55 .PP
56 プログラマは、少なくとも \fIn\fP 個のワイド文字が入る領域を \fIdest\fP に確保しなければならない。
57 .SH 返り値
58 \fBwcpncpy\fP()  は、最後に書き込まれたワイド文字へのポインタ、 すなわち \fIdest\fP+\fIn\fP\-1 を返す。
59 .SH 準拠
60 POSIX.1\-2008.
61 .SH 関連項目
62 \fBstpncpy\fP(3), \fBwcsncpy\fP(3)
63 .SH この文書について
64 この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 3.52 の一部
65 である。プロジェクトの説明とバグ報告に関する情報は
66 http://www.kernel.org/doc/man\-pages/ に書かれている。