annotate gcc/ada/libgnat/a-stzsup.ads @ 131:84e7813d76e9

gcc-8.2
author mir3636
date Thu, 25 Oct 2018 07:37:49 +0900
parents 04ced10e8804
children 1830386684a0
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 ------------------------------------------------------------------------------
kono
parents:
diff changeset
2 -- --
kono
parents:
diff changeset
3 -- GNAT RUN-TIME COMPONENTS --
kono
parents:
diff changeset
4 -- --
kono
parents:
diff changeset
5 -- A D A . S T R I N G S . W I D E _ W I D E _ S U P E R B O U N D E D --
kono
parents:
diff changeset
6 -- --
kono
parents:
diff changeset
7 -- S p e c --
kono
parents:
diff changeset
8 -- --
131
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
9 -- Copyright (C) 2003-2018, Free Software Foundation, Inc. --
111
kono
parents:
diff changeset
10 -- --
kono
parents:
diff changeset
11 -- GNAT is free software; you can redistribute it and/or modify it under --
kono
parents:
diff changeset
12 -- terms of the GNU General Public License as published by the Free Soft- --
kono
parents:
diff changeset
13 -- ware Foundation; either version 3, or (at your option) any later ver- --
kono
parents:
diff changeset
14 -- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
kono
parents:
diff changeset
15 -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
kono
parents:
diff changeset
16 -- or FITNESS FOR A PARTICULAR PURPOSE. --
kono
parents:
diff changeset
17 -- --
kono
parents:
diff changeset
18 -- As a special exception under Section 7 of GPL version 3, you are granted --
kono
parents:
diff changeset
19 -- additional permissions described in the GCC Runtime Library Exception, --
kono
parents:
diff changeset
20 -- version 3.1, as published by the Free Software Foundation. --
kono
parents:
diff changeset
21 -- --
kono
parents:
diff changeset
22 -- You should have received a copy of the GNU General Public License and --
kono
parents:
diff changeset
23 -- a copy of the GCC Runtime Library Exception along with this program; --
kono
parents:
diff changeset
24 -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
kono
parents:
diff changeset
25 -- <http://www.gnu.org/licenses/>. --
kono
parents:
diff changeset
26 -- --
kono
parents:
diff changeset
27 -- GNAT was originally developed by the GNAT team at New York University. --
kono
parents:
diff changeset
28 -- Extensive contributions were provided by Ada Core Technologies Inc. --
kono
parents:
diff changeset
29 -- --
kono
parents:
diff changeset
30 ------------------------------------------------------------------------------
kono
parents:
diff changeset
31
kono
parents:
diff changeset
32 -- This non generic package contains most of the implementation of the
kono
parents:
diff changeset
33 -- generic package Ada.Strings.Wide_Wide_Bounded.Generic_Bounded_Length.
kono
parents:
diff changeset
34
kono
parents:
diff changeset
35 -- It defines type Super_String as a discriminated record with the maximum
kono
parents:
diff changeset
36 -- length as the discriminant. Individual instantiations of the package
kono
parents:
diff changeset
37 -- Strings.Wide_Wide_Bounded.Generic_Bounded_Length use this type with
kono
parents:
diff changeset
38 -- an appropriate discriminant value set.
kono
parents:
diff changeset
39
kono
parents:
diff changeset
40 with Ada.Strings.Wide_Wide_Maps;
kono
parents:
diff changeset
41
kono
parents:
diff changeset
42 package Ada.Strings.Wide_Wide_Superbounded is
kono
parents:
diff changeset
43 pragma Preelaborate;
kono
parents:
diff changeset
44
kono
parents:
diff changeset
45 Wide_Wide_NUL : constant Wide_Wide_Character :=
kono
parents:
diff changeset
46 Wide_Wide_Character'Val (0);
kono
parents:
diff changeset
47
kono
parents:
diff changeset
48 -- Wide_Wide_Bounded.Generic_Bounded_Length.Wide_Wide_Bounded_String is
kono
parents:
diff changeset
49 -- derived from Super_String, with the constraint of the maximum length.
kono
parents:
diff changeset
50
kono
parents:
diff changeset
51 type Super_String (Max_Length : Positive) is record
kono
parents:
diff changeset
52 Current_Length : Natural := 0;
kono
parents:
diff changeset
53 Data : Wide_Wide_String (1 .. Max_Length);
kono
parents:
diff changeset
54 -- A previous version had a default initial value for Data, which is
kono
parents:
diff changeset
55 -- no longer necessary, because we now special-case this type in the
kono
parents:
diff changeset
56 -- compiler, so "=" composes properly for descendants of this type.
kono
parents:
diff changeset
57 -- Leaving it out is more efficient.
kono
parents:
diff changeset
58 end record;
kono
parents:
diff changeset
59
kono
parents:
diff changeset
60 -- The subprograms defined for Super_String are similar to those defined
kono
parents:
diff changeset
61 -- for Bounded_Wide_Wide_String, except that they have different names, so
kono
parents:
diff changeset
62 -- that they can be renamed in Wide_Wide_Bounded.Generic_Bounded_Length.
kono
parents:
diff changeset
63
kono
parents:
diff changeset
64 function Super_Length (Source : Super_String) return Natural;
kono
parents:
diff changeset
65
kono
parents:
diff changeset
66 --------------------------------------------------------
kono
parents:
diff changeset
67 -- Conversion, Concatenation, and Selection Functions --
kono
parents:
diff changeset
68 --------------------------------------------------------
kono
parents:
diff changeset
69
kono
parents:
diff changeset
70 function To_Super_String
kono
parents:
diff changeset
71 (Source : Wide_Wide_String;
kono
parents:
diff changeset
72 Max_Length : Natural;
kono
parents:
diff changeset
73 Drop : Truncation := Error) return Super_String;
kono
parents:
diff changeset
74 -- Note the additional parameter Max_Length, which specifies the maximum
kono
parents:
diff changeset
75 -- length setting of the resulting Super_String value.
kono
parents:
diff changeset
76
kono
parents:
diff changeset
77 -- The following procedures have declarations (and semantics) that are
kono
parents:
diff changeset
78 -- exactly analogous to those declared in Ada.Strings.Wide_Wide_Bounded.
kono
parents:
diff changeset
79
kono
parents:
diff changeset
80 function Super_To_String (Source : Super_String) return Wide_Wide_String;
kono
parents:
diff changeset
81
kono
parents:
diff changeset
82 procedure Set_Super_String
kono
parents:
diff changeset
83 (Target : out Super_String;
kono
parents:
diff changeset
84 Source : Wide_Wide_String;
kono
parents:
diff changeset
85 Drop : Truncation := Error);
kono
parents:
diff changeset
86
kono
parents:
diff changeset
87 function Super_Append
kono
parents:
diff changeset
88 (Left : Super_String;
kono
parents:
diff changeset
89 Right : Super_String;
kono
parents:
diff changeset
90 Drop : Truncation := Error) return Super_String;
kono
parents:
diff changeset
91
kono
parents:
diff changeset
92 function Super_Append
kono
parents:
diff changeset
93 (Left : Super_String;
kono
parents:
diff changeset
94 Right : Wide_Wide_String;
kono
parents:
diff changeset
95 Drop : Truncation := Error) return Super_String;
kono
parents:
diff changeset
96
kono
parents:
diff changeset
97 function Super_Append
kono
parents:
diff changeset
98 (Left : Wide_Wide_String;
kono
parents:
diff changeset
99 Right : Super_String;
kono
parents:
diff changeset
100 Drop : Truncation := Error) return Super_String;
kono
parents:
diff changeset
101
kono
parents:
diff changeset
102 function Super_Append
kono
parents:
diff changeset
103 (Left : Super_String;
kono
parents:
diff changeset
104 Right : Wide_Wide_Character;
kono
parents:
diff changeset
105 Drop : Truncation := Error) return Super_String;
kono
parents:
diff changeset
106
kono
parents:
diff changeset
107 function Super_Append
kono
parents:
diff changeset
108 (Left : Wide_Wide_Character;
kono
parents:
diff changeset
109 Right : Super_String;
kono
parents:
diff changeset
110 Drop : Truncation := Error) return Super_String;
kono
parents:
diff changeset
111
kono
parents:
diff changeset
112 procedure Super_Append
kono
parents:
diff changeset
113 (Source : in out Super_String;
kono
parents:
diff changeset
114 New_Item : Super_String;
kono
parents:
diff changeset
115 Drop : Truncation := Error);
kono
parents:
diff changeset
116
kono
parents:
diff changeset
117 procedure Super_Append
kono
parents:
diff changeset
118 (Source : in out Super_String;
kono
parents:
diff changeset
119 New_Item : Wide_Wide_String;
kono
parents:
diff changeset
120 Drop : Truncation := Error);
kono
parents:
diff changeset
121
kono
parents:
diff changeset
122 procedure Super_Append
kono
parents:
diff changeset
123 (Source : in out Super_String;
kono
parents:
diff changeset
124 New_Item : Wide_Wide_Character;
kono
parents:
diff changeset
125 Drop : Truncation := Error);
kono
parents:
diff changeset
126
kono
parents:
diff changeset
127 function Concat
kono
parents:
diff changeset
128 (Left : Super_String;
kono
parents:
diff changeset
129 Right : Super_String) return Super_String;
kono
parents:
diff changeset
130
kono
parents:
diff changeset
131 function Concat
kono
parents:
diff changeset
132 (Left : Super_String;
kono
parents:
diff changeset
133 Right : Wide_Wide_String) return Super_String;
kono
parents:
diff changeset
134
kono
parents:
diff changeset
135 function Concat
kono
parents:
diff changeset
136 (Left : Wide_Wide_String;
kono
parents:
diff changeset
137 Right : Super_String) return Super_String;
kono
parents:
diff changeset
138
kono
parents:
diff changeset
139 function Concat
kono
parents:
diff changeset
140 (Left : Super_String;
kono
parents:
diff changeset
141 Right : Wide_Wide_Character) return Super_String;
kono
parents:
diff changeset
142
kono
parents:
diff changeset
143 function Concat
kono
parents:
diff changeset
144 (Left : Wide_Wide_Character;
kono
parents:
diff changeset
145 Right : Super_String) return Super_String;
kono
parents:
diff changeset
146
kono
parents:
diff changeset
147 function Super_Element
kono
parents:
diff changeset
148 (Source : Super_String;
kono
parents:
diff changeset
149 Index : Positive) return Wide_Wide_Character;
kono
parents:
diff changeset
150
kono
parents:
diff changeset
151 procedure Super_Replace_Element
kono
parents:
diff changeset
152 (Source : in out Super_String;
kono
parents:
diff changeset
153 Index : Positive;
kono
parents:
diff changeset
154 By : Wide_Wide_Character);
kono
parents:
diff changeset
155
kono
parents:
diff changeset
156 function Super_Slice
kono
parents:
diff changeset
157 (Source : Super_String;
kono
parents:
diff changeset
158 Low : Positive;
kono
parents:
diff changeset
159 High : Natural) return Wide_Wide_String;
kono
parents:
diff changeset
160
kono
parents:
diff changeset
161 function Super_Slice
kono
parents:
diff changeset
162 (Source : Super_String;
kono
parents:
diff changeset
163 Low : Positive;
kono
parents:
diff changeset
164 High : Natural) return Super_String;
kono
parents:
diff changeset
165
kono
parents:
diff changeset
166 procedure Super_Slice
kono
parents:
diff changeset
167 (Source : Super_String;
kono
parents:
diff changeset
168 Target : out Super_String;
kono
parents:
diff changeset
169 Low : Positive;
kono
parents:
diff changeset
170 High : Natural);
kono
parents:
diff changeset
171
kono
parents:
diff changeset
172 function "="
kono
parents:
diff changeset
173 (Left : Super_String;
kono
parents:
diff changeset
174 Right : Super_String) return Boolean;
kono
parents:
diff changeset
175
kono
parents:
diff changeset
176 function Equal
kono
parents:
diff changeset
177 (Left : Super_String;
kono
parents:
diff changeset
178 Right : Super_String) return Boolean renames "=";
kono
parents:
diff changeset
179
kono
parents:
diff changeset
180 function Equal
kono
parents:
diff changeset
181 (Left : Super_String;
kono
parents:
diff changeset
182 Right : Wide_Wide_String) return Boolean;
kono
parents:
diff changeset
183
kono
parents:
diff changeset
184 function Equal
kono
parents:
diff changeset
185 (Left : Wide_Wide_String;
kono
parents:
diff changeset
186 Right : Super_String) return Boolean;
kono
parents:
diff changeset
187
kono
parents:
diff changeset
188 function Less
kono
parents:
diff changeset
189 (Left : Super_String;
kono
parents:
diff changeset
190 Right : Super_String) return Boolean;
kono
parents:
diff changeset
191
kono
parents:
diff changeset
192 function Less
kono
parents:
diff changeset
193 (Left : Super_String;
kono
parents:
diff changeset
194 Right : Wide_Wide_String) return Boolean;
kono
parents:
diff changeset
195
kono
parents:
diff changeset
196 function Less
kono
parents:
diff changeset
197 (Left : Wide_Wide_String;
kono
parents:
diff changeset
198 Right : Super_String) return Boolean;
kono
parents:
diff changeset
199
kono
parents:
diff changeset
200 function Less_Or_Equal
kono
parents:
diff changeset
201 (Left : Super_String;
kono
parents:
diff changeset
202 Right : Super_String) return Boolean;
kono
parents:
diff changeset
203
kono
parents:
diff changeset
204 function Less_Or_Equal
kono
parents:
diff changeset
205 (Left : Super_String;
kono
parents:
diff changeset
206 Right : Wide_Wide_String) return Boolean;
kono
parents:
diff changeset
207
kono
parents:
diff changeset
208 function Less_Or_Equal
kono
parents:
diff changeset
209 (Left : Wide_Wide_String;
kono
parents:
diff changeset
210 Right : Super_String) return Boolean;
kono
parents:
diff changeset
211
kono
parents:
diff changeset
212 function Greater
kono
parents:
diff changeset
213 (Left : Super_String;
kono
parents:
diff changeset
214 Right : Super_String) return Boolean;
kono
parents:
diff changeset
215
kono
parents:
diff changeset
216 function Greater
kono
parents:
diff changeset
217 (Left : Super_String;
kono
parents:
diff changeset
218 Right : Wide_Wide_String) return Boolean;
kono
parents:
diff changeset
219
kono
parents:
diff changeset
220 function Greater
kono
parents:
diff changeset
221 (Left : Wide_Wide_String;
kono
parents:
diff changeset
222 Right : Super_String) return Boolean;
kono
parents:
diff changeset
223
kono
parents:
diff changeset
224 function Greater_Or_Equal
kono
parents:
diff changeset
225 (Left : Super_String;
kono
parents:
diff changeset
226 Right : Super_String) return Boolean;
kono
parents:
diff changeset
227
kono
parents:
diff changeset
228 function Greater_Or_Equal
kono
parents:
diff changeset
229 (Left : Super_String;
kono
parents:
diff changeset
230 Right : Wide_Wide_String) return Boolean;
kono
parents:
diff changeset
231
kono
parents:
diff changeset
232 function Greater_Or_Equal
kono
parents:
diff changeset
233 (Left : Wide_Wide_String;
kono
parents:
diff changeset
234 Right : Super_String) return Boolean;
kono
parents:
diff changeset
235
kono
parents:
diff changeset
236 ----------------------
kono
parents:
diff changeset
237 -- Search Functions --
kono
parents:
diff changeset
238 ----------------------
kono
parents:
diff changeset
239
kono
parents:
diff changeset
240 function Super_Index
kono
parents:
diff changeset
241 (Source : Super_String;
kono
parents:
diff changeset
242 Pattern : Wide_Wide_String;
kono
parents:
diff changeset
243 Going : Direction := Forward;
kono
parents:
diff changeset
244 Mapping : Wide_Wide_Maps.Wide_Wide_Character_Mapping :=
kono
parents:
diff changeset
245 Wide_Wide_Maps.Identity)
kono
parents:
diff changeset
246 return Natural;
kono
parents:
diff changeset
247
kono
parents:
diff changeset
248 function Super_Index
kono
parents:
diff changeset
249 (Source : Super_String;
kono
parents:
diff changeset
250 Pattern : Wide_Wide_String;
kono
parents:
diff changeset
251 Going : Direction := Forward;
kono
parents:
diff changeset
252 Mapping : Wide_Wide_Maps.Wide_Wide_Character_Mapping_Function)
kono
parents:
diff changeset
253 return Natural;
kono
parents:
diff changeset
254
kono
parents:
diff changeset
255 function Super_Index
kono
parents:
diff changeset
256 (Source : Super_String;
kono
parents:
diff changeset
257 Set : Wide_Wide_Maps.Wide_Wide_Character_Set;
kono
parents:
diff changeset
258 Test : Membership := Inside;
kono
parents:
diff changeset
259 Going : Direction := Forward) return Natural;
kono
parents:
diff changeset
260
kono
parents:
diff changeset
261 function Super_Index
kono
parents:
diff changeset
262 (Source : Super_String;
kono
parents:
diff changeset
263 Pattern : Wide_Wide_String;
kono
parents:
diff changeset
264 From : Positive;
kono
parents:
diff changeset
265 Going : Direction := Forward;
kono
parents:
diff changeset
266 Mapping : Wide_Wide_Maps.Wide_Wide_Character_Mapping :=
kono
parents:
diff changeset
267 Wide_Wide_Maps.Identity)
kono
parents:
diff changeset
268 return Natural;
kono
parents:
diff changeset
269
kono
parents:
diff changeset
270 function Super_Index
kono
parents:
diff changeset
271 (Source : Super_String;
kono
parents:
diff changeset
272 Pattern : Wide_Wide_String;
kono
parents:
diff changeset
273 From : Positive;
kono
parents:
diff changeset
274 Going : Direction := Forward;
kono
parents:
diff changeset
275 Mapping : Wide_Wide_Maps.Wide_Wide_Character_Mapping_Function)
kono
parents:
diff changeset
276 return Natural;
kono
parents:
diff changeset
277
kono
parents:
diff changeset
278 function Super_Index
kono
parents:
diff changeset
279 (Source : Super_String;
kono
parents:
diff changeset
280 Set : Wide_Wide_Maps.Wide_Wide_Character_Set;
kono
parents:
diff changeset
281 From : Positive;
kono
parents:
diff changeset
282 Test : Membership := Inside;
kono
parents:
diff changeset
283 Going : Direction := Forward) return Natural;
kono
parents:
diff changeset
284
kono
parents:
diff changeset
285 function Super_Index_Non_Blank
kono
parents:
diff changeset
286 (Source : Super_String;
kono
parents:
diff changeset
287 Going : Direction := Forward) return Natural;
kono
parents:
diff changeset
288
kono
parents:
diff changeset
289 function Super_Index_Non_Blank
kono
parents:
diff changeset
290 (Source : Super_String;
kono
parents:
diff changeset
291 From : Positive;
kono
parents:
diff changeset
292 Going : Direction := Forward) return Natural;
kono
parents:
diff changeset
293
kono
parents:
diff changeset
294 function Super_Count
kono
parents:
diff changeset
295 (Source : Super_String;
kono
parents:
diff changeset
296 Pattern : Wide_Wide_String;
kono
parents:
diff changeset
297 Mapping : Wide_Wide_Maps.Wide_Wide_Character_Mapping :=
kono
parents:
diff changeset
298 Wide_Wide_Maps.Identity)
kono
parents:
diff changeset
299 return Natural;
kono
parents:
diff changeset
300
kono
parents:
diff changeset
301 function Super_Count
kono
parents:
diff changeset
302 (Source : Super_String;
kono
parents:
diff changeset
303 Pattern : Wide_Wide_String;
kono
parents:
diff changeset
304 Mapping : Wide_Wide_Maps.Wide_Wide_Character_Mapping_Function)
kono
parents:
diff changeset
305 return Natural;
kono
parents:
diff changeset
306
kono
parents:
diff changeset
307 function Super_Count
kono
parents:
diff changeset
308 (Source : Super_String;
kono
parents:
diff changeset
309 Set : Wide_Wide_Maps.Wide_Wide_Character_Set) return Natural;
kono
parents:
diff changeset
310
kono
parents:
diff changeset
311 procedure Super_Find_Token
kono
parents:
diff changeset
312 (Source : Super_String;
kono
parents:
diff changeset
313 Set : Wide_Wide_Maps.Wide_Wide_Character_Set;
kono
parents:
diff changeset
314 From : Positive;
kono
parents:
diff changeset
315 Test : Membership;
kono
parents:
diff changeset
316 First : out Positive;
kono
parents:
diff changeset
317 Last : out Natural);
kono
parents:
diff changeset
318
kono
parents:
diff changeset
319 procedure Super_Find_Token
kono
parents:
diff changeset
320 (Source : Super_String;
kono
parents:
diff changeset
321 Set : Wide_Wide_Maps.Wide_Wide_Character_Set;
kono
parents:
diff changeset
322 Test : Membership;
kono
parents:
diff changeset
323 First : out Positive;
kono
parents:
diff changeset
324 Last : out Natural);
kono
parents:
diff changeset
325
kono
parents:
diff changeset
326 ------------------------------------
kono
parents:
diff changeset
327 -- String Translation Subprograms --
kono
parents:
diff changeset
328 ------------------------------------
kono
parents:
diff changeset
329
kono
parents:
diff changeset
330 function Super_Translate
kono
parents:
diff changeset
331 (Source : Super_String;
kono
parents:
diff changeset
332 Mapping : Wide_Wide_Maps.Wide_Wide_Character_Mapping)
kono
parents:
diff changeset
333 return Super_String;
kono
parents:
diff changeset
334
kono
parents:
diff changeset
335 procedure Super_Translate
kono
parents:
diff changeset
336 (Source : in out Super_String;
kono
parents:
diff changeset
337 Mapping : Wide_Wide_Maps.Wide_Wide_Character_Mapping);
kono
parents:
diff changeset
338
kono
parents:
diff changeset
339 function Super_Translate
kono
parents:
diff changeset
340 (Source : Super_String;
kono
parents:
diff changeset
341 Mapping : Wide_Wide_Maps.Wide_Wide_Character_Mapping_Function)
kono
parents:
diff changeset
342 return Super_String;
kono
parents:
diff changeset
343
kono
parents:
diff changeset
344 procedure Super_Translate
kono
parents:
diff changeset
345 (Source : in out Super_String;
kono
parents:
diff changeset
346 Mapping : Wide_Wide_Maps.Wide_Wide_Character_Mapping_Function);
kono
parents:
diff changeset
347
kono
parents:
diff changeset
348 ---------------------------------------
kono
parents:
diff changeset
349 -- String Transformation Subprograms --
kono
parents:
diff changeset
350 ---------------------------------------
kono
parents:
diff changeset
351
kono
parents:
diff changeset
352 function Super_Replace_Slice
kono
parents:
diff changeset
353 (Source : Super_String;
kono
parents:
diff changeset
354 Low : Positive;
kono
parents:
diff changeset
355 High : Natural;
kono
parents:
diff changeset
356 By : Wide_Wide_String;
kono
parents:
diff changeset
357 Drop : Truncation := Error) return Super_String;
kono
parents:
diff changeset
358
kono
parents:
diff changeset
359 procedure Super_Replace_Slice
kono
parents:
diff changeset
360 (Source : in out Super_String;
kono
parents:
diff changeset
361 Low : Positive;
kono
parents:
diff changeset
362 High : Natural;
kono
parents:
diff changeset
363 By : Wide_Wide_String;
kono
parents:
diff changeset
364 Drop : Truncation := Error);
kono
parents:
diff changeset
365
kono
parents:
diff changeset
366 function Super_Insert
kono
parents:
diff changeset
367 (Source : Super_String;
kono
parents:
diff changeset
368 Before : Positive;
kono
parents:
diff changeset
369 New_Item : Wide_Wide_String;
kono
parents:
diff changeset
370 Drop : Truncation := Error) return Super_String;
kono
parents:
diff changeset
371
kono
parents:
diff changeset
372 procedure Super_Insert
kono
parents:
diff changeset
373 (Source : in out Super_String;
kono
parents:
diff changeset
374 Before : Positive;
kono
parents:
diff changeset
375 New_Item : Wide_Wide_String;
kono
parents:
diff changeset
376 Drop : Truncation := Error);
kono
parents:
diff changeset
377
kono
parents:
diff changeset
378 function Super_Overwrite
kono
parents:
diff changeset
379 (Source : Super_String;
kono
parents:
diff changeset
380 Position : Positive;
kono
parents:
diff changeset
381 New_Item : Wide_Wide_String;
kono
parents:
diff changeset
382 Drop : Truncation := Error) return Super_String;
kono
parents:
diff changeset
383
kono
parents:
diff changeset
384 procedure Super_Overwrite
kono
parents:
diff changeset
385 (Source : in out Super_String;
kono
parents:
diff changeset
386 Position : Positive;
kono
parents:
diff changeset
387 New_Item : Wide_Wide_String;
kono
parents:
diff changeset
388 Drop : Truncation := Error);
kono
parents:
diff changeset
389
kono
parents:
diff changeset
390 function Super_Delete
kono
parents:
diff changeset
391 (Source : Super_String;
kono
parents:
diff changeset
392 From : Positive;
kono
parents:
diff changeset
393 Through : Natural) return Super_String;
kono
parents:
diff changeset
394
kono
parents:
diff changeset
395 procedure Super_Delete
kono
parents:
diff changeset
396 (Source : in out Super_String;
kono
parents:
diff changeset
397 From : Positive;
kono
parents:
diff changeset
398 Through : Natural);
kono
parents:
diff changeset
399
kono
parents:
diff changeset
400 ---------------------------------
kono
parents:
diff changeset
401 -- String Selector Subprograms --
kono
parents:
diff changeset
402 ---------------------------------
kono
parents:
diff changeset
403
kono
parents:
diff changeset
404 function Super_Trim
kono
parents:
diff changeset
405 (Source : Super_String;
kono
parents:
diff changeset
406 Side : Trim_End) return Super_String;
kono
parents:
diff changeset
407
kono
parents:
diff changeset
408 procedure Super_Trim
kono
parents:
diff changeset
409 (Source : in out Super_String;
kono
parents:
diff changeset
410 Side : Trim_End);
kono
parents:
diff changeset
411
kono
parents:
diff changeset
412 function Super_Trim
kono
parents:
diff changeset
413 (Source : Super_String;
kono
parents:
diff changeset
414 Left : Wide_Wide_Maps.Wide_Wide_Character_Set;
kono
parents:
diff changeset
415 Right : Wide_Wide_Maps.Wide_Wide_Character_Set) return Super_String;
kono
parents:
diff changeset
416
kono
parents:
diff changeset
417 procedure Super_Trim
kono
parents:
diff changeset
418 (Source : in out Super_String;
kono
parents:
diff changeset
419 Left : Wide_Wide_Maps.Wide_Wide_Character_Set;
kono
parents:
diff changeset
420 Right : Wide_Wide_Maps.Wide_Wide_Character_Set);
kono
parents:
diff changeset
421
kono
parents:
diff changeset
422 function Super_Head
kono
parents:
diff changeset
423 (Source : Super_String;
kono
parents:
diff changeset
424 Count : Natural;
kono
parents:
diff changeset
425 Pad : Wide_Wide_Character := Wide_Wide_Space;
kono
parents:
diff changeset
426 Drop : Truncation := Error) return Super_String;
kono
parents:
diff changeset
427
kono
parents:
diff changeset
428 procedure Super_Head
kono
parents:
diff changeset
429 (Source : in out Super_String;
kono
parents:
diff changeset
430 Count : Natural;
kono
parents:
diff changeset
431 Pad : Wide_Wide_Character := Wide_Wide_Space;
kono
parents:
diff changeset
432 Drop : Truncation := Error);
kono
parents:
diff changeset
433
kono
parents:
diff changeset
434 function Super_Tail
kono
parents:
diff changeset
435 (Source : Super_String;
kono
parents:
diff changeset
436 Count : Natural;
kono
parents:
diff changeset
437 Pad : Wide_Wide_Character := Wide_Wide_Space;
kono
parents:
diff changeset
438 Drop : Truncation := Error) return Super_String;
kono
parents:
diff changeset
439
kono
parents:
diff changeset
440 procedure Super_Tail
kono
parents:
diff changeset
441 (Source : in out Super_String;
kono
parents:
diff changeset
442 Count : Natural;
kono
parents:
diff changeset
443 Pad : Wide_Wide_Character := Wide_Wide_Space;
kono
parents:
diff changeset
444 Drop : Truncation := Error);
kono
parents:
diff changeset
445
kono
parents:
diff changeset
446 ------------------------------------
kono
parents:
diff changeset
447 -- String Constructor Subprograms --
kono
parents:
diff changeset
448 ------------------------------------
kono
parents:
diff changeset
449
kono
parents:
diff changeset
450 -- Note: in some of the following routines, there is an extra parameter
kono
parents:
diff changeset
451 -- Max_Length which specifies the value of the maximum length for the
kono
parents:
diff changeset
452 -- resulting Super_String value.
kono
parents:
diff changeset
453
kono
parents:
diff changeset
454 function Times
kono
parents:
diff changeset
455 (Left : Natural;
kono
parents:
diff changeset
456 Right : Wide_Wide_Character;
kono
parents:
diff changeset
457 Max_Length : Positive) return Super_String;
kono
parents:
diff changeset
458 -- Note the additional parameter Max_Length
kono
parents:
diff changeset
459
kono
parents:
diff changeset
460 function Times
kono
parents:
diff changeset
461 (Left : Natural;
kono
parents:
diff changeset
462 Right : Wide_Wide_String;
kono
parents:
diff changeset
463 Max_Length : Positive) return Super_String;
kono
parents:
diff changeset
464 -- Note the additional parameter Max_Length
kono
parents:
diff changeset
465
kono
parents:
diff changeset
466 function Times
kono
parents:
diff changeset
467 (Left : Natural;
kono
parents:
diff changeset
468 Right : Super_String) return Super_String;
kono
parents:
diff changeset
469
kono
parents:
diff changeset
470 function Super_Replicate
kono
parents:
diff changeset
471 (Count : Natural;
kono
parents:
diff changeset
472 Item : Wide_Wide_Character;
kono
parents:
diff changeset
473 Drop : Truncation := Error;
kono
parents:
diff changeset
474 Max_Length : Positive) return Super_String;
kono
parents:
diff changeset
475 -- Note the additional parameter Max_Length
kono
parents:
diff changeset
476
kono
parents:
diff changeset
477 function Super_Replicate
kono
parents:
diff changeset
478 (Count : Natural;
kono
parents:
diff changeset
479 Item : Wide_Wide_String;
kono
parents:
diff changeset
480 Drop : Truncation := Error;
kono
parents:
diff changeset
481 Max_Length : Positive) return Super_String;
kono
parents:
diff changeset
482 -- Note the additional parameter Max_Length
kono
parents:
diff changeset
483
kono
parents:
diff changeset
484 function Super_Replicate
kono
parents:
diff changeset
485 (Count : Natural;
kono
parents:
diff changeset
486 Item : Super_String;
kono
parents:
diff changeset
487 Drop : Truncation := Error) return Super_String;
kono
parents:
diff changeset
488
kono
parents:
diff changeset
489 private
kono
parents:
diff changeset
490 -- Pragma Inline declarations
kono
parents:
diff changeset
491
kono
parents:
diff changeset
492 pragma Inline ("=");
kono
parents:
diff changeset
493 pragma Inline (Less);
kono
parents:
diff changeset
494 pragma Inline (Less_Or_Equal);
kono
parents:
diff changeset
495 pragma Inline (Greater);
kono
parents:
diff changeset
496 pragma Inline (Greater_Or_Equal);
kono
parents:
diff changeset
497 pragma Inline (Concat);
kono
parents:
diff changeset
498 pragma Inline (Super_Count);
kono
parents:
diff changeset
499 pragma Inline (Super_Element);
kono
parents:
diff changeset
500 pragma Inline (Super_Find_Token);
kono
parents:
diff changeset
501 pragma Inline (Super_Index);
kono
parents:
diff changeset
502 pragma Inline (Super_Index_Non_Blank);
kono
parents:
diff changeset
503 pragma Inline (Super_Length);
kono
parents:
diff changeset
504 pragma Inline (Super_Replace_Element);
kono
parents:
diff changeset
505 pragma Inline (Super_Slice);
kono
parents:
diff changeset
506 pragma Inline (Super_To_String);
kono
parents:
diff changeset
507
kono
parents:
diff changeset
508 end Ada.Strings.Wide_Wide_Superbounded;