OSDN Git Service

(split) Import translated manuals from JM CVS Repository.
[linuxjm/LDP_man-pages.git] / draft / man3 / isalpha.3
1 .\" Copyright (c) 1993 by Thomas Koenig (ig25@rz.uni-karlsruhe.de)
2 .\"
3 .\" Permission is granted to make and distribute verbatim copies of this
4 .\" manual provided the copyright notice and this permission notice are
5 .\" preserved on all copies.
6 .\"
7 .\" Permission is granted to copy and distribute modified versions of this
8 .\" manual under the conditions for verbatim copying, provided that the
9 .\" entire resulting derived work is distributed under the terms of a
10 .\" permission notice identical to this one.
11 .\"
12 .\" Since the Linux kernel and libraries are constantly changing, this
13 .\" manual page may be incorrect or out-of-date.  The author(s) assume no
14 .\" responsibility for errors or omissions, or for damages resulting from
15 .\" the use of the information contained herein.  The author(s) may not
16 .\" have taken the same level of care in the production of this manual,
17 .\" which is licensed free of charge, as they might when working
18 .\" professionally.
19 .\"
20 .\" Formatted or processed versions of this manual, if unaccompanied by
21 .\" the source, must acknowledge the copyright and authors of this work.
22 .\" License.
23 .\"
24 .\" Modified Sat Jul 24 19:10:00 1993 by Rik Faith (faith@cs.unc.edu)
25 .\" Modified Sun Aug 21 17:51:50 1994 by Rik Faith (faith@cs.unc.edu)
26 .\" Modified Sat Sep  2 21:52:01 1995 by Jim Van Zandt <jrv@vanzandt.mv.com>
27 .\" Modified Mon May 27 22:55:26 1996 by Martin Schulze (joey@linux.de)
28 .\"
29 .\" Japanese Version Copyright (c) 1997 Ueyama Rui
30 .\"         all rights reserved.
31 .\" Translated 1997-08-29, Ueyama Rui <rui@campus.or.jp>
32 .\" Updated 1999-07-16, Kentaro Shirakata <argrath@yo.rim.or.jp>
33 .\" Updated 2005-02-26, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
34 .\" Updated 2007-05-01, Akihiro MOTOKI, LDP v2.46
35 .\"
36 .TH ISALPHA 3 2009-03-15 "GNU" "Linux Programmer's Manual"
37 .\"O .SH NAME
38 .SH Ì¾Á°
39 .\"O isalnum, isalpha, isascii, isblank, iscntrl, isdigit, isgraph, islower,
40 .\"O isprint, ispunct, isspace, isupper, isxdigit \- character
41 .\"O classification routines
42 isalnum, isalpha, isascii, isblank, iscntrl, isdigit, isgraph, islower,
43 isprint, ispunct, isspace, isupper, isxdigit \- Ê¸»ú¤òʬÎह¤ë
44 .\"O .SH SYNOPSIS
45 .SH ½ñ¼°
46 .nf
47 .B #include <ctype.h>
48 .sp
49 .BI "int isalnum(int " "c" );
50 .br
51 .BI "int isalpha(int " "c" );
52 .br
53 .BI "int isascii(int " "c" );
54 .br
55 .BI "int isblank(int " "c" );
56 .br
57 .BI "int iscntrl(int " "c" );
58 .br
59 .BI "int isdigit(int " "c" );
60 .br
61 .BI "int isgraph(int " "c" );
62 .br
63 .BI "int islower(int " "c" );
64 .br
65 .BI "int isprint(int " "c" );
66 .br
67 .BI "int ispunct(int " "c" );
68 .br
69 .BI "int isspace(int " "c" );
70 .br
71 .BI "int isupper(int " "c" );
72 .br
73 .BI "int isxdigit(int " "c" );
74 .fi
75 .sp
76 .in -4n
77 .\"O Feature Test Macro Requirements for glibc (see
78 .\"O .BR feature_test_macros (7)):
79 glibc ¸þ¤±¤Îµ¡Ç½¸¡ºº¥Þ¥¯¥í¤ÎÍ×·ï
80 .RB ( feature_test_macros (7)
81 »²¾È):
82 .in
83 .sp
84 .ad l
85 .BR isascii ():
86 _BSD_SOURCE || _SVID_SOURCE || _XOPEN_SOURCE
87 .br
88 .BR isblank ():
89 _XOPEN_SOURCE\ >=\ 600 || _ISOC99_SOURCE; or
90 .I cc\ -std=c99
91 .ad b
92 .\"O .SH DESCRIPTION
93 .SH ÀâÌÀ
94 .\"O These functions check whether
95 .\"O .IR c ,
96 .\"O which must have the value of an
97 .\"O .I unsigned char
98 .\"O or
99 .\"O .BR EOF ,
100 .\"O falls into a certain character class according to the current locale.
101 ¤³¤ì¤é¤Î´Ø¿ô¤Ï¡¢¸½ºß¤Î¥í¥±¡¼¥ë¤Ë½¾¤Ã¤Æ
102 .I c
103 ¤òʬÎह¤ë¡£
104 .I c
105 ¤Ï
106 .I unsigned char
107 ¤«
108 .B EOF
109 ¤Ç¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤¡£
110 .TP
111 .BR isalnum ()
112 .\"O checks for an alphanumeric character; it is equivalent to
113 .\"O .BI "(isalpha(" c ") || isdigit(" c "))" \fR.
114 ±Ñ»ú¤Þ¤¿¤Ï¿ô»ú¤Ç¤¢¤ë¤«¤òÄ´¤Ù¤ë¡£
115 .BI "(isalpha(" c ") || isdigit(" c "))" \fR
116 ¤ÈÅù²Á¤Ç¤¢¤ë¡£
117 .TP
118 .BR isalpha ()
119 .\"O checks for an alphabetic character; in the standard \fB"C"\fP
120 .\"O locale, it is equivalent to
121 .\"O .BI "(isupper(" c ") || islower(" c "))" \fR.
122 .\"O In some locales, there may be additional characters for which
123 .\"O .BR isalpha ()
124 .\"O is true\-\-letters which are neither upper case nor lower
125 .\"O case.
126 ¥¢¥ë¥Õ¥¡¥Ù¥Ã¥È¤«¤É¤¦¤«Ä´¤Ù¤ë¡£É¸½à¤Î \fB"C"\fP ¥í¥±¡¼¥ë¤Ç¤Ï
127 .BI "(isupper(" c ") || islower(" c "))" \fR
128 ¤ÈÅù²Á¤Ç¤¢¤ë¡£Â¾¤Î¥í¥±¡¼¥ë¤Ç¤Ï¡¢Âçʸ»ú¤Ç¤â¾®Ê¸»ú¤Ç¤â¤Ê¤¤Â¾¤Îʸ»ú¤Ç¤â
129 .BR isalpha ()
130 ¤¬ true ¤òÊÖ¤¹¤³¤È¤¬¤¢¤ë¡£
131 .TP
132 .BR isascii ()
133 .\"O checks whether \fIc\fP is a 7-bit
134 .\"O .I unsigned char
135 .\"O value that fits into
136 .\"O the ASCII character set.
137 \fIc\fP ¤¬¡¢ASCIIʸ»ú¥»¥Ã¥È¤Ë¹çÃפ¹¤ë 7¥Ó¥Ã¥È¤Î
138 .I unsigned char
139 ¤Ç¤¢¤ë¤«¤òÄ´¤Ù¤ë¡£
140 .TP
141 .BR isblank ()
142 .\"O checks for a blank character; that is, a space or a tab.
143 ¶õÇòʸ»ú (¥¹¥Ú¡¼¥¹¤«¥¿¥Ö) ¤Ç¤¢¤ë¤«¤òÄ´¤Ù¤ë¡£
144 .TP
145 .BR iscntrl ()
146 .\"O checks for a control character.
147 À©¸æʸ»ú¤«¤É¤¦¤«¤òÄ´¤Ù¤ë¡£
148 .TP
149 .BR isdigit ()
150 .\"O checks for a digit (0 through 9).
151 ¿ô»ú (0¡Á9) ¤«¤É¤¦¤«¤òÄ´¤Ù¤ë¡£
152 .TP
153 .BR isgraph ()
154 .\"O checks for any printable character except space.
155 ɽ¼¨²Äǽ¤Êʸ»ú¤«¤É¤¦¤«¤òÄ´¤Ù¤ë¡£¥¹¥Ú¡¼¥¹¤Ï´Þ¤Þ¤ì¤Ê¤¤¡£
156 .TP
157 .BR islower ()
158 .\"O checks for a lower-case character.
159 ¾®Ê¸»ú¤«¤É¤¦¤«¤òÄ´¤Ù¤ë¡£
160 .TP
161 .BR isprint ()
162 .\"O checks for any printable character including space.
163 ɽ¼¨²Äǽ¤Êʸ»ú¤«¤É¤¦¤«¤òÄ´¤Ù¤ë¡£¥¹¥Ú¡¼¥¹¤â´Þ¤Þ¤ì¤ë¡£
164 .TP
165 .BR ispunct ()
166 .\"O checks for any printable character which is not a space or an
167 .\"O alphanumeric character.
168 ɽ¼¨²Äǽ¤Êʸ»ú¤«¤É¤¦¤«¤òÄ´¤Ù¤ë¡£¥¹¥Ú¡¼¥¹¤È±Ñ¿ô»ú¤Ï´Þ¤Þ¤ì¤Ê¤¤¡£
169 .TP
170 .BR isspace ()
171 .\"O checks for white-space characters.
172 .\"O In the
173 .\"O .B """C"""
174 .\"O and
175 .\"O .B """POSIX"""
176 .\"O locales, these are: space, form-feed
177 .\"O .RB ( \(aq\ef\(aq ),
178 .\"O newline
179 .\"O .RB ( \(aq\en\(aq ),
180 .\"O carriage return
181 .\"O .RB ( \(aq\er\(aq ),
182 .\"O horizontal tab
183 .\"O .RB ( \(aq\et\(aq ),
184 .\"O and vertical tab
185 .\"O .RB ( \(aq\ev\(aq ).
186 .\"O .TP
187 .\"O .BR isupper ()
188 .\"O checks for an uppercase letter.
189 ¶õÇòʸ»ú¤«¤É¤¦¤«¤òÄ´¤Ù¤ë¡£
190 .B """C"""
191 ¥í¥±¡¼¥ë¤«
192 .B """POSIX"""
193 ¥í¥±¡¼¥ë¤Ç¤Ï¡¢¶õÇòʸ»ú¤È¤Ï¡¢¥¹¥Ú¡¼¥¹¡¢¥Õ¥©¡¼¥à¥Õ¥£¡¼¥É
194 .RB ( \(aq\ef\(aq )
195 ¡¢²þ¹Ô(newline)
196 .RB ( \(aq\en\(aq )
197 ¡¢Éüµ¢(carriage return)
198 .RB ( \(aq\er\(aq )
199 ¡¢¿åÊ¿¥¿¥Ö
200 .RB ( \(aq\et\(aq )
201 ¡¢¿âľ¥¿¥Ö
202 .RB ( \(aq\ev\(aq )
203 ¤Ç¤¢¤ë¡£
204 .TP
205 .BR isupper ()
206 .\"O checks for an uppercase letter.
207 ¾®Ê¸»ú¤«¤É¤¦¤«¤òÄ´¤Ù¤ë¡£
208 .TP
209 .BR isxdigit ()
210 .\"O checks for a hexadecimal digits, that is, one of
211 .\"O .br
212 .\"O .BR "0 1 2 3 4 5 6 7 8 9 a b c d e f A B C D E F" .
213 16¿Ê¿ô¤Ç¤Î¿ô»ú¤«¤É¤¦¤«¤òÄ´¤Ù¤ë¡£
214 .br
215 .B "0 1 2 3 4 5 6 7 8 9 a b c d e f A B C D E F"
216 ¤Îʸ»ú¤Ç¤¢¤ë¤«¤É¤¦¤«¤òÄ´¤Ù¤ë¤³¤È¤ÈÅù²Á¤Ç¤¢¤ë¡£
217 .\"O .SH "RETURN VALUE"
218 .SH ÊÖ¤êÃÍ
219 .\"O The values returned are nonzero if the character
220 .\"O .I c
221 .\"O falls into the tested class, and a zero value
222 .\"O if not.
223 ʸ»ú
224 .I c
225 ¤¬Ä´¤Ù¤¿Ê¸»ú¤Î¼ïÎà¤Ë¹ç¤Ã¤Æ¤¤¤ì¤Ð 0 °Ê³°¤òÊÖ¤¹¡£
226 ¤½¤¦¤Ç¤Ê¤±¤ì¤Ð 0 ¤òÊÖ¤¹¡£
227 .\"O .SH "CONFORMING TO"
228 .SH ½àµò
229 .\"O C99, 4.3BSD.
230 .\"O C89 specifies all of these functions except
231 .\"O .BR isascii ()
232 .\"O and
233 .\"O .BR isblank ().
234 .\"O .BR isascii ()
235 .\"O is a BSD extension
236 .\"O and is also an SVr4 extension.
237 .\"O .BR isblank ()
238 .\"O conforms to POSIX.1-2001 and C99 7.4.1.3.
239 C99, 4.3BSD.
240 C89 ¤Ç¤Ï¡¢¤³¤ì¤é¤Î´Ø¿ô¤Î¤¦¤Á
241 .BR isascii ()
242 ¤È
243 .BR isblank ()
244 °Ê³°¤Î
245 ¤¹¤Ù¤Æ¤¬µ¬Äꤵ¤ì¤Æ¤¤¤ë¡£
246 .BR isascii ()
247 ¤Ï BSD ¤ä SVr4 ¤Î³ÈÄ¥¤Ç¤¢¤ë¡£
248 .BR isblank ()
249 ¤Ï POSIX.1-2001 ¤È C99 7.4.1.3 ¤Ë½àµò¤·¤Æ¤¤¤ë¡£
250 .\"O POSIX.1-2008 marks
251 .\"O .BR isascii ()
252 .\"O as obsolete,
253 .\"O noting that it cannot be used portably in a localized application.
254 POSIX.1-2008 ¤Ï¡¢
255 .BR isascii ()
256 ¤òÇÑ»ßͽÄê¤È¤·¤Æ¤¤¤ë¡£
257 ¥í¡¼¥«¥é¥¤¥º¤µ¤ì¤¿¥¢¥×¥ê¥±¡¼¥·¥ç¥ó¤Ç¤Ï¡¢°Ü¿¢À­¤ò³ÎÊݤ·¤Ä¤Ä¡¢
258 ¤³¤Î´Ø¿ô¤ò»ÈÍѤ¹¤ë¤³¤È¤Ï¤Ç¤­¤Ê¤¤ÅÀ¤ËÃí°Õ¤¹¤ë¤³¤È¡£
259 .\"O .SH NOTES
260 .SH Ãí°Õ
261 .\"O The details of what characters belong into which class depend on the current
262 .\"O locale.
263 .\"O For example,
264 .\"O .BR isupper ()
265 .\"O will not recognize an A-umlaut (\(:A) as an uppercase letter in the default
266 .\"O .B "C"
267 .\"O locale.
268 ¤¢¤ëʸ»ú¤¬¤É¤Î¼ïÎà¤ËÆþ¤ë¤«¤È¤¤¤¦¤³¤È¤Ï¡¢¸½ºß¤Î¥í¥±¡¼¥ë¤Ë°Í¸¤¹¤ë¡£
269 ¤¿¤È¤¨¤Ð¡¢¥Ç¥Õ¥©¥ë¥È¤Î
270 .B "C"
271 ¥í¥±¡¼¥ë¤Ç¤Ï
272 .BR isupper ()
273 ¤Ï A ¤Î¥¦¥à¥é¥¦¥È¤òǧ¼±¤Ç¤­¤Ê¤¤¤Î¤Ç¡¢¤½¤ì¤¬Âçʸ»ú¤À¤È¤¤¤¦¤³¤È¤¬¤ï¤«¤é¤Ê¤¤¡£
274 .\"O .SH "SEE ALSO"
275 .SH ´ØÏ¢¹àÌÜ
276 .BR iswalnum (3),
277 .BR iswalpha (3),
278 .BR iswblank (3),
279 .BR iswcntrl (3),
280 .BR iswdigit (3),
281 .BR iswgraph (3),
282 .BR iswlower (3),
283 .BR iswprint (3),
284 .BR iswpunct (3),
285 .BR iswspace (3),
286 .BR iswupper (3),
287 .BR iswxdigit (3),
288 .BR setlocale (3),
289 .BR toascii (3),
290 .BR tolower (3),
291 .BR toupper (3),
292 .BR ascii (7),
293 .BR locale (7)