OSDN Git Service

Daily bump.
[pf3gnuchains/gcc-fork.git] / gcc / ada / a-zchhan.ads
1 ------------------------------------------------------------------------------
2 --                                                                          --
3 --                         GNAT RUN-TIME COMPONENTS                         --
4 --                                                                          --
5 --    A D A . W I D E _ W I D E _ C H A R A C T E R S . H A N D L I N G     --
6 --                                                                          --
7 --                                 S p e c                                  --
8 --                                                                          --
9 -- This specification is derived from the Ada Reference Manual for use with --
10 -- GNAT.  In accordance with the copyright of that document, you can freely --
11 -- copy and modify this specification,  provided that if you redistribute a --
12 -- modified version,  any changes that you have made are clearly indicated. --
13 --                                                                          --
14 ------------------------------------------------------------------------------
15
16 package Ada.Wide_Wide_Characters.Handling is
17    pragma Pure;
18    --  This package is clearly intended to be Pure, by analogy with the
19    --  base Ada.Characters.Handling package. The version in the RM does
20    --  not yet have this pragma, but that is a clear omission. This will
21    --  be fixed in a future version of AI05-0266-1.
22
23    function Is_Control (Item : Wide_Wide_Character) return Boolean;
24    pragma Inline (Is_Control);
25    --  Returns True if the Wide_Wide_Character designated by Item is
26    --  categorized as other_control, otherwise returns false.
27
28    function Is_Letter (Item : Wide_Wide_Character) return Boolean;
29    pragma Inline (Is_Letter);
30    --  Returns True if the Wide_Wide_Character designated by Item is
31    --  categorized as letter_uppercase, letter_lowercase, letter_titlecase,
32    --  letter_modifier, letter_other, or number_letter. Otherwise returns
33    --  false.
34
35    function Is_Lower (Item : Wide_Wide_Character) return Boolean;
36    pragma Inline (Is_Lower);
37    --  Returns True if the Wide_Wide_Character designated by Item is
38    --  categorized as letter_lowercase, otherwise returns false.
39
40    function Is_Upper (Item : Wide_Wide_Character) return Boolean;
41    pragma Inline (Is_Upper);
42    --  Returns True if the Wide_Wide_Character designated by Item is
43    --  categorized as letter_uppercase, otherwise returns false.
44
45    function Is_Digit (Item : Wide_Wide_Character) return Boolean;
46    pragma Inline (Is_Digit);
47    --  Returns True if the Wide_Wide_Character designated by Item is
48    --  categorized as number_decimal, otherwise returns false.
49
50    function Is_Decimal_Digit (Item : Wide_Wide_Character) return Boolean
51      renames Is_Digit;
52
53    function Is_Hexadecimal_Digit (Item : Wide_Wide_Character) return Boolean;
54    --  Returns True if the Wide_Wide_Character designated by Item is
55    --  categorized as number_decimal, or is in the range 'A' .. 'F' or
56    --  'a' .. 'f', otherwise returns false.
57
58    function Is_Alphanumeric (Item : Wide_Wide_Character) return Boolean;
59    pragma Inline (Is_Alphanumeric);
60    --  Returns True if the Wide_Wide_Character designated by Item is
61    --  categorized as letter_uppercase, letter_lowercase, letter_titlecase,
62    --  letter_modifier, letter_other, number_letter, or number_decimal.
63    --  Otherwise returns false.
64
65    function Is_Special (Item : Wide_Wide_Character) return Boolean;
66    pragma Inline (Is_Special);
67    --  Returns True if the Wide_Wide_Character designated by Item
68    --  is categorized as graphic_character, but not categorized as
69    --  letter_uppercase, letter_lowercase, letter_titlecase, letter_modifier,
70    --  letter_other, number_letter, or number_decimal. Otherwise returns false.
71
72    function Is_Line_Terminator (Item : Wide_Wide_Character) return Boolean;
73    pragma Inline (Is_Line_Terminator);
74    --  Returns True if the Wide_Wide_Character designated by Item is
75    --  categorized as separator_line or separator_paragraph, or if Item is a
76    --  conventional line terminator character (CR, LF, VT, or FF). Otherwise
77    --  returns false.
78
79    function Is_Mark (Item : Wide_Wide_Character) return Boolean;
80    pragma Inline (Is_Mark);
81    --  Returns True if the Wide_Wide_Character designated by Item is
82    --  categorized as mark_non_spacing or mark_spacing_combining, otherwise
83    --  returns false.
84
85    function Is_Other (Item : Wide_Wide_Character) return Boolean;
86    pragma Inline (Is_Other);
87    --  Returns True if the Wide_Wide_Character designated by Item is
88    --  categorized as other_format, otherwise returns false.
89
90    function Is_Punctuation (Item : Wide_Wide_Character) return Boolean;
91    pragma Inline (Is_Punctuation);
92    --  Returns True if the Wide_Wide_Character designated by Item is
93    --  categorized as punctuation_connector, otherwise returns false.
94
95    function Is_Space (Item : Wide_Wide_Character) return Boolean;
96    pragma Inline (Is_Space);
97    --  Returns True if the Wide_Wide_Character designated by Item is
98    --  categorized as separator_space, otherwise returns false.
99
100    function Is_Graphic (Item : Wide_Wide_Character) return Boolean;
101    pragma Inline (Is_Graphic);
102    --  Returns True if the Wide_Wide_Character designated by Item is
103    --  categorized as graphic_character, otherwise returns false.
104
105    function To_Lower (Item : Wide_Wide_Character) return Wide_Wide_Character;
106    pragma Inline (To_Lower);
107    --  Returns the Simple Lowercase Mapping of the Wide_Wide_Character
108    --  designated by Item. If the Simple Lowercase Mapping does not exist for
109    --  the Wide_Wide_Character designated by Item, then the value of Item is
110    --  returned.
111
112    function To_Lower (Item : Wide_Wide_String) return Wide_Wide_String;
113    --  Returns the result of applying the To_Lower Wide_Wide_Character to
114    --  Wide_Wide_Character conversion to each element of the Wide_Wide_String
115    --  designated by Item. The result is the null Wide_Wide_String if the value
116    --  of the formal parameter is the null Wide_Wide_String.
117
118    function To_Upper (Item : Wide_Wide_Character) return Wide_Wide_Character;
119    pragma Inline (To_Upper);
120    --  Returns the Simple Uppercase Mapping of the Wide_Wide_Character
121    --  designated by Item. If the Simple Uppercase Mapping does not exist for
122    --  the Wide_Wide_Character designated by Item, then the value of Item is
123    --  returned.
124
125    function To_Upper (Item : Wide_Wide_String) return Wide_Wide_String;
126    --  Returns the result of applying the To_Upper Wide_Wide_Character to
127    --  Wide_Wide_Character conversion to each element of the Wide_Wide_String
128    --  designated by Item. The result is the null Wide_Wide_String if the value
129    --  of the formal parameter is the null Wide_Wide_String.
130
131 end Ada.Wide_Wide_Characters.Handling;