1 ------------------------------------------------------------------------------
3 -- GNAT RUNTIME COMPONENTS --
5 -- A D A . S T R I N G S . W I D E _ F I X E D --
9 -- $Revision: 1.11 $ --
11 -- This specification is adapted from the Ada Reference Manual for use with --
12 -- GNAT. In accordance with the copyright of that document, you can freely --
13 -- copy and modify this specification, provided that if you redistribute a --
14 -- modified version, any changes that you have made are clearly indicated. --
16 ------------------------------------------------------------------------------
19 with Ada
.Strings
.Wide_Maps
;
21 package Ada
.Strings
.Wide_Fixed
is
22 pragma Preelaborate
(Wide_Fixed
);
24 -------------------------------------------------------------------
25 -- Copy Procedure for Wide_Strings of Possibly Different Lengths --
26 -------------------------------------------------------------------
29 (Source
: in Wide_String;
30 Target
: out Wide_String;
31 Drop
: in Truncation
:= Error
;
32 Justify
: in Alignment
:= Left
;
33 Pad
: in Wide_Character := Ada
.Strings
.Wide_Space
);
35 ------------------------
36 -- Search Subprograms --
37 ------------------------
40 (Source
: in Wide_String;
41 Pattern
: in Wide_String;
42 Going
: in Direction
:= Forward
;
43 Mapping
: in Wide_Maps
.Wide_Character_Mapping
:= Wide_Maps
.Identity
)
47 (Source
: in Wide_String;
48 Pattern
: in Wide_String;
49 Going
: in Direction
:= Forward
;
50 Mapping
: in Wide_Maps
.Wide_Character_Mapping_Function
)
54 (Source
: in Wide_String;
55 Set
: in Wide_Maps
.Wide_Character_Set
;
56 Test
: in Membership
:= Inside
;
57 Going
: in Direction
:= Forward
)
60 function Index_Non_Blank
61 (Source
: in Wide_String;
62 Going
: in Direction
:= Forward
)
66 (Source
: in Wide_String;
67 Pattern
: in Wide_String;
68 Mapping
: in Wide_Maps
.Wide_Character_Mapping
:= Wide_Maps
.Identity
)
72 (Source
: in Wide_String;
73 Pattern
: in Wide_String;
74 Mapping
: in Wide_Maps
.Wide_Character_Mapping_Function
)
78 (Source
: in Wide_String;
79 Set
: in Wide_Maps
.Wide_Character_Set
)
83 (Source
: in Wide_String;
84 Set
: in Wide_Maps
.Wide_Character_Set
;
89 -----------------------------------------
90 -- Wide_String Translation Subprograms --
91 -----------------------------------------
94 (Source
: in Wide_String;
95 Mapping
: in Wide_Maps
.Wide_Character_Mapping
)
99 (Source
: in out Wide_String;
100 Mapping
: in Wide_Maps
.Wide_Character_Mapping
);
103 (Source
: in Wide_String;
104 Mapping
: in Wide_Maps
.Wide_Character_Mapping_Function
)
108 (Source
: in out Wide_String;
109 Mapping
: in Wide_Maps
.Wide_Character_Mapping_Function
);
111 --------------------------------------------
112 -- Wide_String Transformation Subprograms --
113 --------------------------------------------
115 function Replace_Slice
116 (Source
: in Wide_String;
122 procedure Replace_Slice
123 (Source
: in out Wide_String;
127 Drop
: in Truncation
:= Error
;
128 Justify
: in Alignment
:= Left
;
129 Pad
: in Wide_Character := Ada
.Strings
.Wide_Space
);
132 (Source
: in Wide_String;
133 Before
: in Positive;
134 New_Item
: in Wide_String)
138 (Source
: in out Wide_String;
139 Before
: in Positive;
140 New_Item
: in Wide_String;
141 Drop
: in Truncation
:= Error
);
144 (Source
: in Wide_String;
145 Position
: in Positive;
146 New_Item
: in Wide_String)
150 (Source
: in out Wide_String;
151 Position
: in Positive;
152 New_Item
: in Wide_String;
153 Drop
: in Truncation
:= Right
);
156 (Source
: in Wide_String;
158 Through
: in Natural)
162 (Source
: in out Wide_String;
164 Through
: in Natural;
165 Justify
: in Alignment
:= Left
;
166 Pad
: in Wide_Character := Ada
.Strings
.Wide_Space
);
168 --------------------------------------
169 -- Wide_String Selector Subprograms --
170 --------------------------------------
173 (Source
: in Wide_String;
178 (Source
: in out Wide_String;
180 Justify
: in Alignment
:= Left
;
181 Pad
: in Wide_Character := Wide_Space
);
184 (Source
: in Wide_String;
185 Left
: in Wide_Maps
.Wide_Character_Set
;
186 Right
: in Wide_Maps
.Wide_Character_Set
)
190 (Source
: in out Wide_String;
191 Left
: in Wide_Maps
.Wide_Character_Set
;
192 Right
: in Wide_Maps
.Wide_Character_Set
;
193 Justify
: in Alignment
:= Ada
.Strings
.Left
;
194 Pad
: in Wide_Character := Ada
.Strings
.Wide_Space
);
197 (Source
: in Wide_String;
199 Pad
: in Wide_Character := Ada
.Strings
.Wide_Space
)
203 (Source
: in out Wide_String;
205 Justify
: in Alignment
:= Left
;
206 Pad
: in Wide_Character := Ada
.Strings
.Wide_Space
);
209 (Source
: in Wide_String;
211 Pad
: in Wide_Character := Ada
.Strings
.Wide_Space
)
215 (Source
: in out Wide_String;
217 Justify
: in Alignment
:= Left
;
218 Pad
: in Wide_Character := Ada
.Strings
.Wide_Space
);
220 ---------------------------------------
221 -- Wide_String Constructor Functions --
222 ---------------------------------------
226 Right
: in Wide_Character)
231 Right
: in Wide_String)
234 end Ada
.Strings
.Wide_Fixed
;