ANNEXES
--- The Detailed Node Listing ---
ANNEXES
!topic Title summarizing comment !reference RM95-ss.ss(pp) !from Author Name yy-mm-dd !keywords keywords related to topic !discussion text of discussion
!topic [c]{C}haracter
!topic it[']s meaning is not defined
--- The Detailed Node Listing ---
The form or contents of any listings produced by implementations; in particular, the form or contents of error or warning messages;
NOTES
NOTES
case_statement
array
return_statement ::= return [expression]; return_statement ::= return; | return expression;
term ::= factor {multiplying_operator factor}
term ::= factor | term multiplying_operator factor
constraint ::= scalar_constraint | composite_constraint
discrete_choice_list ::= discrete_choice {| discrete_choice}
NOTES
if_statement ::=
if condition then
sequence_of_statements
{elsif condition then
sequence_of_statements}
[else
sequence_of_statements]
end if;
--- The Detailed Node Listing ---
character ::=
graphic_character
| format_effector
| other_control_function
graphic_character ::=
identifier_letter
| digit
| space_character
| special_character
upper_case_identifier_letter | lower_case_identifier_letter
Any character of Row 00 of ISO 10646 BMP whose name begins ``Latin Capital Letter''.
Any character of Row 00 of ISO 10646 BMP whose name begins ``Latin Small Letter''.
One of the characters 0, 1, 2, 3, 4, 5, 6, 7, 8, or 9.
The character of ISO 10646 BMP named ``Space''.
Any character of the ISO 10646 BMP that is not reserved for a control function, and is not the space_character, an identifier_letter, or a digit.
The control functions of ISO 6429 called character tabulation (HT), line tabulation (VT), carriage return (CR), line feed (LF), and form feed (FF).
Any control function, other than a format_effector, that is allowed in a comment; the set of other_control_functions allowed in comments is implementation defined.
symbol name symbol name
" quotation mark : colon
# number sign ; semicolon
& ampersand < less-than sign
' apostrophe, tick = equals sign
( left parenthesis > greater-than sign
) right parenthesis _ low line, underline
* asterisk, multiply | vertical line
+ plus sign [ left square bracket
, comma ] right square bracket
- hyphen-minus, minus { left curly bracket
. full stop, dot, point } right curly bracket
/ solidus, divide
NOTES
& ' ( ) * + , - . / : ; < = > |
=> .. ** := /= >= <= << >> <>
delimiter name => arrow .. double dot ** double star, exponentiate := assignment (pronounced: ``becomes'') /= inequality (pronounced: ``not equal'') >= greater than or equal <= less than or equal << left label bracket >> right label bracket <> box
identifier ::= identifier_letter {[underline] letter_or_digit}
letter_or_digit ::= identifier_letter | digit
Count X Get_Symbol Ethelyn Marion Snobol_4 X1 Page_Count Store_Next_Item
numeric_literal ::= decimal_literal | based_literal
NOTES
decimal_literal ::= numeral [.numeral] [exponent]
numeral ::= digit {[underline] digit}
exponent ::= E [+] numeral | E - numeral
12 0 1E6 123_456 -- integer literals 12.0 0.0 0.456 3.14159_26 -- real literals
based_literal ::= base # based_numeral [.based_numeral] # [exponent]
base ::= numeral
based_numeral ::=
extended_digit {[underline] extended_digit}
extended_digit ::= digit | A | B | C | D | E | F
2#1111_1111# 16#FF# 016#0ff# -- integer literals of value 255 16#E#E1 2#1110_0000# -- integer literals of value 224 16#F.FF#E+2 2#1.1111_1111_1110#E11 -- real literals of value 4095.0
character_literal ::= 'graphic_character'
NOTES
'A' '*' ''' ' '
string_literal ::= "{string_element}"
string_element ::= "" | non_quotation_mark_graphic_character
NOTES
"Message of the day:" "" -- a null string literal " " "A" """" -- three string literals of length 1 "Characters such as $, %, and } are allowed in string literals"
comment ::= --{non_end_of_line_character}
-- the last sentence above echoes the Algol 68 report end; -- processing of Line is complete -- a long comment may be split onto -- two or more consecutive lines ---------------- the first two hyphens start the comment
pragma ::=
pragma identifier [(pragma_argument_association
{, pragma_argument_association})];
pragma_argument_association ::=
[pragma_argument_identifier =>] name
| [pragma_argument_identifier =>] expression
pragma List(Off); -- turn off listing generation pragma Optimize(Off); -- turn off optional optimizations pragma Inline(Set_Mask); -- generate code for Set_Mask inline pragma Suppress(Range_Check, On => Index); -- turn off range checking on Index
abort else new return
abs elsif not reverse
abstract end null
accept entry select
access exception separate
aliased exit of subtype
all or
and for others tagged
array function out task
at terminate
generic package then
begin goto pragma type
body private
if procedure
case in protected until
constant is use
raise
declare range when
delay limited record while
delta loop rem with
digits renames
do mod requeue xor
NOTES
--- The Detailed Node Listing ---
basic_declaration ::=
type_declaration | subtype_declaration
| object_declaration | number_declaration
| subprogram_declaration | abstract_subprogram_declaration
| package_declaration | renaming_declaration
| exception_declaration | generic_declaration
| generic_instantiation
defining_identifier ::= identifier
NOTES
NOTES
all types
elementary
scalar
discrete
enumeration
character
boolean
other enumeration
integer
signed integer
modular integer
real
floating point
fixed point
ordinary fixed point
decimal fixed point
access
access-to-object
access-to-subprogram
composite
array
string
other array
untagged record
tagged
task
protected
type_declaration ::=
full_type_declaration
| incomplete_type_declaration
| private_type_declaration
| private_extension_declaration
full_type_declaration ::=
type defining_identifier [known_discriminant_part]
is type_definition;
| task_type_declaration
| protected_type_declaration
type_definition ::=
enumeration_type_definition | integer_type_definition
| real_type_definition | array_type_definition
| record_type_definition | access_type_definition
| derived_type_definition
(White, Red, Yellow, Green, Blue, Brown, Black) range 1 .. 72 array(1 .. 10) of Integer
type Color is (White, Red, Yellow, Green, Blue, Brown, Black); type Column is range 1 .. 72; type Table is array(1 .. 10) of Integer;
NOTES
subtype_declaration ::= subtype defining_identifier is subtype_indication;
subtype_indication ::= subtype_mark [constraint]
subtype_mark ::= subtype_name
constraint ::= scalar_constraint | composite_constraint
scalar_constraint ::= range_constraint | digits_constraint | delta_constraint
composite_constraint ::= index_constraint | discriminant_constraint
NOTES
subtype Rainbow is Color range Red .. Blue; -- see 3.2.1 subtype Red_Blue is Rainbow; subtype Int is Integer; subtype Small_Int is Integer range -10 .. 10; subtype Up_To_K is Column range 1 .. K; -- see 3.2.1 subtype Square is Matrix(1 .. 10, 1 .. 10); -- see 3.6 subtype Male is Person(Sex => M); -- see 3.10.1
NOTES
object_declaration ::=
defining_identifier_list : [aliased] [constant]
subtype_indication [:= expression];
| defining_identifier_list : [aliased] [constant]
array_type_definition [:= expression];
| single_task_declaration
| single_protected_declaration
defining_identifier_list ::=
defining_identifier {, defining_identifier}
NOTES
-- the multiple object declaration
John, Paul : Person_Name := new Person(Sex => M); -- see 3.10.1
-- is equivalent to the two single object -- declarations in the order given
John : Person_Name := new Person(Sex => M); Paul : Person_Name := new Person(Sex => M);
Count, Sum : Integer; Size : Integer range 0 .. 10_000 := 0; Sorted : Boolean := False; Color_Table : array(1 .. Max) of Color; Option : Bit_Vector(1 .. 10) := (others => True); Hello : constant String := "Hi, world.";
Limit : constant Integer := 10_000; Low_Limit : constant Integer := Limit/10; Tolerance : constant Real := Dispersion(1.15);
number_declaration ::= defining_identifier_list : constant := static_expression;
Two_Pi : constant := 2.0*Ada.Numerics.Pi; -- a real number, see A.5
Max : constant := 500; -- an integer number Max_Line_Size : constant := Max/6; -- the integer 83 Power_16 : constant := 2**16; -- the integer 65_536 One, Un, Eins : constant := 1; -- three different names for 1
derived_type_definition ::= [abstract] new parent_subtype_indication [record_extension_part]
NOTES
type Local_Coordinate is new Coordinate; -- two different types type Midweek is new Day range Tue .. Thu; -- see 3.5.1 type Counter is new Positive; -- same range as Positive
type Special_Key is new Key_Manager.Key; -- see 7.3.1 -- the inherited subprograms have the following specifications: -- procedure Get_Key(K : out Special_Key); -- function "<"(X,Y : Special_Key) return Boolean;
NOTES
1 + 4 < 7
range_constraint ::= range range
range ::=
range_attribute_reference
| simple_expression .. simple_expression
S'First denotes the lower bound of the range of S. The value of this attribute is of the type of S.
S'Last denotes the upper bound of the range of S. The value of this attribute is of the type of S.
S'Range is equivalent to the range S'First .. S'Last.
S'Base denotes an unconstrained subtype of the type of S. This unconstrained subtype is called the base subtype of the type.
function S'Min(Left, Right : S'Base) return S'Base
function S'Max(Left, Right : S'Base) return S'Base
function S'Succ(Arg : S'Base) return S'Base
function S'Pred(Arg : S'Base) return S'Base
function S'Wide_Image(Arg : S'Base) return Wide_String
function S'Image(Arg : S'Base) return String
S'Wide_Width denotes the maximum length of a Wide_String returned by S'Wide_Image over all values of the subtype S. It denotes zero for a subtype that has a null range. Its type is universal_integer.
S'Width denotes the maximum length of a String returned by S'Image over all values of the subtype S. It denotes zero for a subtype that has a null range. Its type is universal_integer.
function S'Wide_Value(Arg : Wide_String) return S'Base
function S'Value(Arg : String) return S'Base
NOTES
-10 .. 10 X .. X + 1 0.0 .. 2.0*Pi Red .. Green -- see 3.5.1 1 .. 0 -- a null range Table'Range -- a range attribute reference, see 3.6
range -999.0 .. +999.0 range S'First+1 .. S'Last-1
enumeration_type_definition ::=
(enumeration_literal_specification
{, enumeration_literal_specification})
enumeration_literal_specification ::= defining_identifier | defining_character_literal
defining_character_literal ::= character_literal
NOTES
type Day is (Mon, Tue, Wed, Thu, Fri, Sat, Sun); type Suit is (Clubs, Diamonds, Hearts, Spades); type Gender is (M, F); type Level is (Low, Medium, Urgent); type Color is (White, Red, Yellow, Green, Blue, Brown, Black); type Light is (Red, Amber, Green); -- Red and Green are overloaded
type Hexa is ('A', 'B', 'C', 'D', 'E', 'F');
type Mixed is ('A', 'B', '*', B, None, '?', '%');
subtype Weekday is Day range Mon .. Fri; subtype Major is Suit range Hearts .. Spades; subtype Rainbow is Color range Red .. Blue; -- the Color Red, not the Light
NOTES
type Roman_Digit is ('I', 'V', 'X', 'L', 'C', 'D', 'M');
integer_type_definition ::= signed_integer_type_definition | modular_type_definition
signed_integer_type_definition ::= range static_simple_expression .. static_simple_expression
modular_type_definition ::= mod static_expression
subtype Natural is Integer range 0 .. Integer'Last; subtype Positive is Integer range 1 .. Integer'Last;
S'Modulus yields the modulus of the type of S, as a value of the type universal_integer.
NOTES
type Page_Num is range 1 .. 2_000; type Line_Size is range 1 .. Max_Line_Size;
subtype Small_Int is Integer range -10 .. 10; subtype Column_Ptr is Line_Size range 1 .. 10; subtype Buffer_Size is Integer range 0 .. Max;
type Byte is mod 256; -- an unsigned byte type Hash_Index is mod 97; -- modulus is prime
function S'Pos(Arg : S'Base) return universal_integer
function S'Val(Arg : universal_integer) return S'Base
NOTES
S'Val(S'Pos(X)) = X S'Pos(S'Val(N)) = N
-- For the types and subtypes declared in subclause -- see 3.5.1, the following hold:
-- Color'First = White, Color'Last = Black -- Rainbow'First = Red, Rainbow'Last = Blue
-- Color'Succ(Blue) = Rainbow'Succ(Blue) = Brown -- Color'Pos(Blue) = Rainbow'Pos(Blue) = 4 -- Color'Val(0) = Rainbow'Val(0) = White
real_type_definition ::= floating_point_definition | fixed_point_definition
NOTES
floating_point_definition ::= digits static_expression [real_range_specification]
real_range_specification ::= range static_simple_expression .. static_simple_expression
NOTES
type Coefficient is digits 10 range -1.0 .. 1.0;
type Real is digits 8; type Mass is digits 7 range 0.0 .. 1.0E35;
subtype Probability is Real range 0.0 .. 1.0; -- a subtype with a smaller range
S'Digits denotes the requested decimal precision for the subtype S. The value of this attribute is of the type universal_integer. The requested decimal precision of the base subtype of a floating point type T is defined to be the largest value of d for which ceiling(d * log(10) / log(T'Machine_Radix)) + 1 <= T'Model_Mantissa.
NOTES
fixed_point_definition ::= ordinary_fixed_point_definition | decimal_fixed_point_definition
ordinary_fixed_point_definition ::= delta static_expression real_range_specification
decimal_fixed_point_definition ::=
delta static_expression digits static_expression
[real_range_specification]
digits_constraint ::= digits static_expression [range_constraint]
NOTES
type Fraction is delta 2.0**(-15) range -1.0 .. 1.0;
type Volt is delta 0.125 range 0.0 .. 255.0;
-- A pure fraction which requires all the available -- space in a word can be declared as the type Fraction: type Fraction is delta System.Fine_Delta range -1.0 .. 1.0; -- Fraction'Last = 1.0 - System.Fine_Delta
type Money is delta 0.01 digits 15; -- decimal fixed point subtype Salary is Money digits 10; -- Money'Last = 10.0**13 - 0.01, Salary'Last = 10.0**8 - 0.01
S'Small denotes the small of the type of S. The value of this attribute is of the type universal_real. Small may be specified for nonderived fixed point types via an attribute_definition_clause, see 13.3; the expression of such a clause shall be static.
S'Delta denotes the delta of the fixed point subtype S. The value of this attribute is of the type universal_real.
S'Fore yields the minimum number of characters needed before the decimal point for the decimal representation of any value of the subtype S, assuming that the representation does not include an exponent, but includes a one-character prefix that is either a minus sign or a space. (This minimum number does not include superfluous zeros or underlines, and is at least 2.) The value of this attribute is of the type universal_integer.
S'Aft yields the number of decimal digits needed after the decimal point to accommodate the delta of the subtype S, unless the delta of the subtype S is greater than 0.1, in which case the attribute yields the value one. (S'Aft is the smallest positive integer N for which (10**N)*S'Delta is greater than or equal to one.) The value of this attribute is of the type universal_integer.
S'Digits denotes the digits of the decimal fixed point subtype S, which corresponds to the number of decimal digits that are representable in objects of the subtype. The value of this attribute is of the type universal_integer. Its value is determined as follows:
S'Scale denotes the scale of the subtype S, defined as the value N such that S'Delta = 10.0**(-N). The scale indicates the position of the point relative to the rightmost significant digits of values of subtype S. The value of this attribute is of the type universal_integer.
function S'Round(X : universal_real) return S'Base
NOTES
array_type_definition ::= unconstrained_array_definition | constrained_array_definition
unconstrained_array_definition ::=
array(index_subtype_definition {, index_subtype_definition})
of component_definition
index_subtype_definition ::= subtype_mark range <>
constrained_array_definition ::=
array (discrete_subtype_definition
{, discrete_subtype_definition}) of component_definition
discrete_subtype_definition ::= discrete_subtype_indication | range
component_definition ::= [aliased] subtype_indication
NOTES
type Vector is array(Integer range <>) of Real; type Matrix is array(Integer range <>, Integer range <>) of Real; type Bit_Vector is array(Integer range <>) of Boolean; type Roman is array(Positive range <>) of Roman_Digit; -- see 3.5.2
type Table is array(1 .. 10) of Integer; type Schedule is array(Day) of Boolean; type Line is array(1 .. Max_Line_Size) of Character;
Grid : array(1 .. 80, 1 .. 100) of Boolean; Mix : array(Color range Red .. Green) of Boolean; Page : array(Positive range <>) of Line := -- an array of arrays (1 | 50 => Line'(1 | Line'Last => '+', others => '-'), -- see 4.3.3 2 .. 49 => Line'(1 | Line'Last => '|', others => ' ')); -- Page is constrained by its initial value to (1..50)
index_constraint ::= (discrete_range {, discrete_range})
discrete_range ::= discrete_subtype_indication | range
NOTES
Board : Matrix(1 .. 8, 1 .. 8); -- see 3.6 Rectangle : Matrix(1 .. 20, 1 .. 30); Inverse : Matrix(1 .. N, 1 .. N); -- N need not be static
Filter : Bit_Vector(0 .. 31);
My_Schedule : Schedule; -- all arrays of type Schedule have the same bounds
type Var_Line(Length : Natural) is
record
Image : String(1 .. Length);
end record;
Null_Line : Var_Line(0); -- Null_Line.Image is a null array
A'First denotes the lower bound of the first index range; its type is the corresponding index type.
A'First(N) denotes the lower bound of the N-th index range; its type is the corresponding index type.
A'Last denotes the upper bound of the first index range; its type is the corresponding index type.
A'Last(N) denotes the upper bound of the N-th index range; its type is the corresponding index type.
A'Range is equivalent to the range A'First .. A'Last, except that the prefix A is only evaluated once.
A'Range(N) is equivalent to the range A'First(N) .. A'Last(N), except that the prefix A is only evaluated once.
A'Length denotes the number of values of the first index range (zero for a null range); its type is universal_integer.
A'Length(N) denotes the number of values of the N-th index range (zero for a null range); its type is universal_integer.
NOTES
A'Length(N) = A'Last(N) - A'First(N) + 1
-- Filter'First = 0 -- Filter'Last = 31 -- Filter'Length = 32 -- Rectangle'Last(1) = 20 -- Rectangle'Last(2) = 30
subtype Positive is Integer range 1 .. Integer'Last;
type String is array(Positive range <>) of Character; type Wide_String is array(Positive range <>) of Wide_Character;
NOTES
Stars : String(1 .. 120) := (1 .. 120 => '*' ); Question : constant String := "How many characters?"; -- Question'First = 1, Question'Last = 20 -- Question'Length = 20 (the number of characters)
Ask_Twice : String := Question & Question; -- constrained to (1..40) Ninety_Six : constant Roman := "XCVI"; -- see 3.5.2, and 3.6
discriminant_part ::= unknown_discriminant_part | known_discriminant_part
unknown_discriminant_part ::= (<>)
known_discriminant_part ::=
(discriminant_specification {; discriminant_specification})
discriminant_specification ::=
defining_identifier_list : subtype_mark
[:= default_expression]
| defining_identifier_list : access_definition
[:= default_expression]
default_expression ::= expression
NOTES
type Buffer(Size : Buffer_Size := 100) is -- see 3.5.4 record Pos : Buffer_Size := 0; Value : String(1 .. Size); end record;
type Matrix_Rec(Rows, Columns : Integer) is
record
Mat : Matrix(1 .. Rows, 1 .. Columns); -- see 3.6
end record;
type Square(Side : Integer) is new Matrix_Rec(Rows => Side, Columns => Side);
type Double_Square(Number : Integer) is
record
Left : Square(Number);
Right : Square(Number);
end record;
type Item(Number : Positive) is
record
Content : Integer;
-- no component depends on the discriminant
end record;
discriminant_constraint ::=
(discriminant_association {, discriminant_association})
discriminant_association ::=
[discriminant_selector_name
{| discriminant_selector_name} =>] expression
NOTES
Large : Buffer(200); -- constrained, always 200 characters
-- (explicit discriminant value)
Message : Buffer; -- unconstrained, initially 100 characters
-- (default discriminant value)
Basis : Square(5); -- constrained, always 5 by 5
Illegal : Square; -- illegal, a Square has to be constrained
Yields the value True if A denotes a constant, a value, or a constrained variable, and False otherwise.
record_type_definition ::= [[abstract] tagged] [limited] record_definition
record_definition ::=
record
component_list
end record
| null record
component_list ::=
component_item {component_item}
| {component_item} variant_part
| null;
component_item ::= component_declaration | representation_clause
component_declaration ::=
defining_identifier_list : component_definition
[:= default_expression];
NOTES
type Date is
record
Day : Integer range 1 .. 31;
Month : Month_Name;
Year : Integer range 0 .. 4000;
end record;
type Complex is
record
Re : Real := 0.0;
Im : Real := 0.0;
end record;
Tomorrow, Yesterday : Date; A, B, C : Complex;
-- both components of A, B, and C are implicitly initialized to zero
variant_part ::=
case discriminant_direct_name is
variant
{variant}
end case;
variant ::=
when discrete_choice_list =>
component_list
discrete_choice_list ::= discrete_choice {| discrete_choice}
discrete_choice ::= expression | discrete_range | others
type Device is (Printer, Disk, Drum); type State is (Open, Closed);
type Peripheral(Unit : Device := Disk) is
record
Status : State;
case Unit is
when Printer =>
Line_Count : Integer range 1 .. Page_Size;
when others =>
Cylinder : Cylinder_Index;
Track : Track_Number;
end case;
end record;
subtype Drum_Unit is Peripheral(Drum); subtype Disk_Unit is Peripheral(Disk);
Writer : Peripheral(Unit => Printer); Archive : Disk_Unit;
package Ada.Tags is
type Tag is private;
function Expanded_Name(T : Tag) return String;
function External_Tag(T : Tag) return String;
function Internal_Tag(External : String) return Tag;
Tag_Error : exception;
private ... -- not specified by the language end Ada.Tags;
S'Class denotes a subtype of the class-wide type (called T'Class in this International Standard) for the class rooted at T (or if S already denotes a class-wide subtype, then S'Class is the same as S).
S'Tag denotes the tag of the type T (or if T is class-wide, the tag of the root type of the corresponding class). The value of this attribute is of type Tag.
X'Tag denotes the tag of X. The value of this attribute is of type Tag.
NOTES
type Point is tagged
record
X, Y : Real := 0.0;
end record;
type Expression is tagged null record; -- Components will be added by each extension
record_extension_part ::= with record_definition
NOTES
type Painted_Point is new Point with
record
Paint : Color := White;
end record;
-- Components X and Y are inherited
Origin : constant Painted_Point := (X | Y => 0.0, Paint => Black);
type Literal is new Expression with
record -- a leaf in an Expression tree
Value : Real;
end record;
type Expr_Ptr is access all Expression'Class; -- see 3.10
type Binary_Operation is new Expression with
record -- an internal node in an Expression tree
Left, Right : Expr_Ptr;
end record;
type Addition is new Binary_Operation with null record; type Subtraction is new Binary_Operation with null record; -- No additional components needed for these extensions
Tree : Expr_Ptr := -- A tree representation of ``5.0 + (13.0-7.0)''
new Addition'(
Left => new Literal'(Value => 5.0),
Right => new Subtraction'(
Left => new Literal'(Value => 13.0),
Right => new Literal'(Value => 7.0)));
NOTES
NOTES
package Sets is
subtype Element_Type is Natural;
type Set is abstract tagged null record;
function Empty return Set is abstract;
function Union(Left, Right : Set) return Set is abstract;
function Intersection(Left, Right : Set) return Set is abstract;
function Unit_Set(Element : Element_Type) return Set is abstract;
procedure Take
(Element : out Element_Type;
From : in out Set) is abstract;
end Sets;
NOTES
access_type_definition ::=
access_to_object_definition
| access_to_subprogram_definition
access_to_object_definition ::=
access [general_access_modifier] subtype_indication
general_access_modifier ::= all | constant
access_to_subprogram_definition ::=
access [protected] procedure parameter_profile
| access [protected] function parameter_and_result_profile
access_definition ::= access subtype_mark
NOTES
type Peripheral_Ref is access Peripheral; -- see 3.8.1 type Binop_Ptr is access all Binary_Operation'Class; -- general access-to-class-wide, see 3.9.1
subtype Drum_Ref is Peripheral_Ref(Drum); -- see 3.8.1
type Message_Procedure is access
procedure (M : in String := "Error!");
procedure Default_Message_Procedure(M : in String);
Give_Message : Message_Procedure := Default_Message_Procedure'Access;
...
procedure Other_Procedure(M : in String);
...
Give_Message := Other_Procedure'Access;
...
Give_Message("File not found.");
-- call with parameter (.all is optional)
Give_Message.all;
-- call with no parameters
incomplete_type_declaration ::= type defining_identifier [discriminant_part];
NOTES
type Cell; -- incomplete type declaration type Link is access Cell;
type Cell is
record
Value : Integer;
Succ : Link;
Pred : Link;
end record;
Head : Link := new Cell'(0, null, null); Next : Link := Head.Succ;
type Person(<>); -- incomplete type declaration type Car; -- incomplete type declaration
type Person_Name is access Person; type Car_Name is access all Car;
type Car is
record
Number : Integer;
Owner : Person_Name;
end record;
type Person(Sex : Gender) is
record
Name : String(1 .. 20);
Birth : Date;
Age : Integer range 0 .. 130;
Vehicle : Car_Name;
case Sex is
when M => Wife : Person_Name(Sex => F);
when F => Husband : Person_Name(Sex => M);
end case;
end record;
My_Car, Your_Car, Next_Car : Car_Name := new Car; -- see 4.8 George : Person_Name := new Person(M); ... George.Vehicle := Your_Car;
X'Access yields an access value that designates the object denoted by X. The type of X'Access is an access-to-object type, as determined by the expected type. The expected type shall be a general access type. X shall denote an aliased view of an object, including possibly the current instance (see 8.6) of a limited type within its definition, or a formal parameter or generic formal object of a tagged type. The view denoted by the prefix X shall satisfy the following additional requirements, presuming the expected type for X'Access is the general access type A:
P'Access yields an access value that designates the subprogram denoted by P. The type of P'Access is an access-to-subprogram type (S), as determined by the expected type. The accessibility level of P shall not be statically deeper than that of S. In addition to the places where Legality Rules normally apply, see 12.3, this rule applies also in the private part of an instance of a generic unit. The profile of P shall be subtype-conformant with the designated profile of S, and shall not be Intrinsic. If the subprogram denoted by P is declared within a generic body, S shall be declared within the generic body.
NOTES
Martha : Person_Name := new Person(F); -- see 3.10.1 Cars : array (1..2) of aliased Car; ... Martha.Vehicle := Cars(1)'Access; George.Vehicle := Cars(2)'Access;
declarative_part ::= {declarative_item}
declarative_item ::= basic_declarative_item | body
basic_declarative_item ::= basic_declaration | representation_clause | use_clause
body ::= proper_body | body_stub
proper_body ::= subprogram_body | package_body | task_body | protected_body
NOTES
--- The Detailed Node Listing ---
name ::=
direct_name | explicit_dereference
| indexed_component | slice
| selected_component | attribute_reference
| type_conversion | function_call
| character_literal
direct_name ::= identifier | operator_symbol
prefix ::= name | implicit_dereference
explicit_dereference ::= name.all
implicit_dereference ::= name
Pi -- the direct name of a number (see 3.3.2) Limit -- the direct name of a constant (see 3.3.1) Count -- the direct name of a scalar variable (see 3.3.1) Board -- the direct name of an array variable (see 3.6.1) Matrix -- the direct name of a type (see 3.6) Random -- the direct name of a function (see 6.1) Error -- the direct name of an exception (see 11.1)
Next_Car.all -- explicit dereference denoting the object
-- designated by the access variable Next_Car,
-- see 3.10.1
Next_Car.Owner -- selected component with implicit dereference;
-- same as Next_Car.all.Owner
indexed_component ::= prefix(expression {, expression})
My_Schedule(Sat) -- a component of a one-dimensional array (see see 3.6.1) Page(10) -- a component of a one-dimensional array (see see 3.6) Board(M, J + 1) -- a component of a two-dimensional array (see see 3.6.1) Page(10)(20) -- a component of a component (see see 3.6) Request(Medium) -- an entry in a family of entries (see see 9.1) Next_Frame(L)(M, N) -- a component of a function call (see see 6.1)
NOTES
slice ::= prefix(discrete_range)
NOTES
Stars(1 .. 15) -- a slice of 15 characters (see 3.6.3) Page(10 .. 10 + Size) -- a slice of 1 + Size components (see 3.6) Page(L)(A .. B) -- a slice of the array Page(L) (see 3.6) Stars(1 .. 0) -- a null slice (see 3.6.3) My_Schedule(Weekday) -- bounds given by subtype (see 3.6.1, and 3.5.1) Stars(5 .. 15)(K) -- same as Stars(K) (see 3.6.3) -- provided that K is in 5 .. 15
selected_component ::= prefix . selector_name
selector_name ::= identifier | character_literal | operator_symbol
Tomorrow.Month -- a record component (see 3.8) Next_Car.Owner -- a record component (see 3.10.1) Next_Car.Owner.Age -- a record component (see 3.10.1) -- the previous two lines involve implicit dereferences Writer.Unit -- a record component (a discriminant) (see 3.8.1) Min_Cell(H).Value -- a record component of the result (see 6.1) -- of the function call Min_Cell(H) Control.Seize -- an entry of a protected object (see 9.4) Pool(K).Write -- an entry of the task Pool(K) (see 9.4)
Key_Manager."<" -- an operator of the visible part of a package (see 7.3.1) Dot_Product.Sum -- a variable declared in a function body (see 6.1) Buffer.Pool -- a variable declared in a protected unit (see 9.11) Buffer.Read -- an entry of a protected unit (see 9.11) Swap.Temp -- a variable declared in a block statement (see 5.6) Standard.Boolean -- the name of a predefined type (see A.1)
attribute_reference ::= prefix'attribute_designator
attribute_designator ::=
identifier[(static_expression)]
| Access | Delta | Digits
range_attribute_reference ::= prefix'range_attribute_designator
range_attribute_designator ::= Range[(static_expression)]
NOTES
Color'First -- minimum value of the enumeration type Color (see 3.5.1) Rainbow'Base'First -- same as Color'First (see 3.5.1) Real'Digits -- precision of the type Real (see 3.5.7) Board'Last(2) -- upper bound of the second dimension of Board (see 3.6.1) Board'Range(1) -- index range of the first dimension of Board (see 3.6.1) Pool(K)'Terminated -- True if task Pool(K) is terminated (see 9.1) Date'Size -- number of bits for records of type Date (see 3.8) Message'Address -- address of the record variable Message (see 3.7.1)
NOTES
3.14159_26536 -- a real literal 1_345 -- an integer literal 'A' -- a character literal "Some Text" -- a string literal
aggregate ::= record_aggregate | extension_aggregate | array_aggregate
record_aggregate ::= (record_component_association_list)
record_component_association_list ::=
record_component_association {, record_component_association}
| null record
record_component_association ::= [ component_choice_list => ] expression
component_choice_list ::=
component_selector_name {| component_selector_name}
| others
NOTES
(4, July, 1776) -- see 3.8
(Day => 4, Month => July, Year => 1776) (Month => July, Day => 4, Year => 1776)
(Disk, Closed, Track => 5, Cylinder => 12) -- see 3.8.1 (Unit => Disk, Status => Closed, Cylinder => 9, Track => 1)
(Value => 0, Succ|Pred => new Cell'(0, null, null)) -- see 3.10.1
-- The allocator is evaluated twice: -- Succ and Pred designate different cells
Expression'(null record) Literal'(Value => 0.0) Painted_Point'(0.0, Pi/2.0, Paint => Red)
extension_aggregate ::= (ancestor_part with record_component_association_list)
ancestor_part ::= expression | subtype_mark
NOTES
Painted_Point'(Point with Red) (Point'(P) with Paint => Black)
(Expression with Left => 1.2, Right => 3.4) Addition'(Binop with null record) -- presuming Binop is of type Binary_Operation
array_aggregate ::= positional_array_aggregate | named_array_aggregate
positional_array_aggregate ::=
(expression, expression {, expression})
| (expression {, expression}, others => expression)
named_array_aggregate ::=
(array_component_association {, array_component_association})
array_component_association ::= discrete_choice_list => expression
NOTES
(7, 9, 5, 1, 3, 2, 4, 8, 6, 0) Table'(5, 8, 4, 1, others => 0) -- see 3.6
(1 .. 5 => (1 .. 8 => 0.0)) -- two-dimensional (1 .. N => new Cell) -- N new cells, in particular for N = 0
Table'(2 | 4 | 10 => 1, others => 0) Schedule'(Mon .. Fri => True, others => False) Schedule'(Wed | Sun => False, others => True) -- see 3.6 Vector'(1 => 2.5) -- single-component vector
-- Three aggregates for the same value of subtype -- Matrix(1..2,1..3), see 3.6
((1.1, 1.2, 1.3), (2.1, 2.2, 2.3)) (1 => (1.1, 1.2, 1.3), 2 => (2.1, 2.2, 2.3)) (1 => (1 => 1.1, 2 => 1.2, 3 => 1.3), 2 => (1 => 2.1, 2 => 2.2, 3 => 2.3))
A : Table := (7, 9, 5, 1, 3, 2, 4, 8, 6, 0); -- A(1)=7, A(10)=0 B : Table := (2 | 4 | 10 => 1, others => 0); -- B(1)=0, B(10)=1 C : constant Matrix := (1 .. 5 => (1 .. 8 => 0.0)); -- C'Last(1)=5, C'Last(2)=8
D : Bit_Vector(M .. N) := (M .. N => True); -- see 3.6 E : Bit_Vector(M .. N) := (others => True); F : String(1 .. 1) := (1 => 'F'); -- a one component aggregate: same as "F"
expression ::=
relation {and relation} | relation {and then relation}
| relation {or relation} | relation {or else relation}
| relation {xor relation}
relation ::=
simple_expression [relational_operator simple_expression]
| simple_expression [not] in range
| simple_expression [not] in subtype_mark
simple_expression ::=
[unary_adding_operator] term {binary_adding_operator term}
term ::= factor {multiplying_operator factor}
factor ::= primary [** primary] | abs primary | not primary
primary ::=
numeric_literal | null
| string_literal | aggregate
| name | qualified_expression
| allocator | (expression)
4.0 -- real literal Pi -- named number (1 .. 10 => 0) -- array aggregate Sum -- variable Integer'Last -- attribute Sine(X) -- function call Color'(Blue) -- qualified expression Real(M*N) -- conversion (Line_Count + 10) -- parenthesized expression
Volume -- primary not Destroyed -- factor 2*Line_Count -- term -4.0 -- simple expression -4.0 + A -- simple expression B**2 - 4.0*A*C -- simple expression Password(1 .. 3) = "Bwv" -- relation Count in Small_Int -- relation Count not in Small_Int -- relation Index = 0 or Item_Hit -- expression (Cold and Sunny) or Warm -- expression (parentheses are required) A**(B**C) -- expression (parentheses are required)
logical_operator ::= and | or | xor
relational_operator ::= = | /= | < | <= | > | >=
binary_adding_operator ::= + | - | &
unary_adding_operator ::= + | -
multiplying_operator ::= * | / | mod | rem
highest_precedence_operator ::= ** | abs | not
NOTES
not Sunny or Warm -- same as (not Sunny) or Warm X > 4.0 and Y > 0.0 -- same as (X > 4.0) and (Y > 0.0)
-4.0*A**2 -- same as -(4.0 * (A**2)) abs(1 + A) + B -- same as (abs (1 + A)) + B Y**(-3) -- parentheses are necessary A / B * C -- same as (A/B)*C A + (B + C) -- evaluate B + C before adding it to A
function "and"(Left, Right : T) return T function "or" (Left, Right : T) return T function "xor"(Left, Right : T) return T
NOTES
A B (A and B) (A or B) (A xor B) True True True True False True False False True True False True False True True False False False False False
Sunny or Warm Filter(1 .. 10) and Filter(15 .. 24) -- see 3.6.1
Next_Car.Owner /= null and then Next_Car.Owner.Age > 25 -- see 3.10.1 N = 0 or else A(N) = Hit_Value
function "=" (Left, Right : T) return Boolean function "/="(Left, Right : T) return Boolean
function "<" (Left, Right : T) return Boolean function "<="(Left, Right : T) return Boolean function ">" (Left, Right : T) return Boolean function ">="(Left, Right : T) return Boolean
NOTES
X /= Y
"" < "A" and "A" < "Aa" -- True "Aa" < "B" and "A" < "A " -- True
My_Car = null -- true if My_Car has been set to null (see 3.10.1) My_Car = Your_Car -- true if we both share the same car My_Car.all = Your_Car.all -- true if the two cars are identical
N not in 1 .. 10 -- range membership test Today in Mon .. Fri -- range membership test Today in Weekday -- subtype membership test (see 3.5.1) Archive in Disk_Unit -- subtype membership test, see 3.8.1 Tree.all in Addition'Class -- class membership test (see 3.9.1)
function "+"(Left, Right : T) return T function "-"(Left, Right : T) return T
function "&"(Left : T; Right : T) return T function "&"(Left : T; Right : C) return T function "&"(Left : C; Right : T) return T function "&"(Left : C; Right : C) return T
NOTES
Z + 0.1 -- Z has to be of a real type
"A" & "BCD" -- concatenation of two string literals 'A' & "BCD" -- concatenation of a character literal and a string literal 'A' & 'A' -- concatenation of two character literals
function "+"(Right : T) return T function "-"(Right : T) return T
NOTES
function "*" (Left, Right : T) return T function "/" (Left, Right : T) return T function "mod"(Left, Right : T) return T function "rem"(Left, Right : T) return T
A = (A/B)*B + (A rem B)
(-A)/B = -(A/B) = A/(-B)
A = B*N + (A mod B)
function "*"(Left, Right : T) return T function "/"(Left, Right : T) return T
function "*"(Left : T; Right : Integer) return T function "*"(Left : Integer; Right : T) return T function "/"(Left : T; Right : Integer) return T
function "*"(Left, Right : root_real) return root_real function "/"(Left, Right : root_real) return root_real
function "*"(Left : root_real; Right : root_integer) return root_real function "*"(Left : root_integer; Right : root_real) return root_real function "/"(Left : root_real; Right : root_integer) return root_real
function "*"(Left, Right : universal_fixed) return universal_fixed function "/"(Left, Right : universal_fixed) return universal_fixed
NOTES
A rem (-B) = A rem B (-A) rem B = -(A rem B)
A mod B = (A + K*B) mod B
A B A/B A rem B A mod B A B A/B A rem B A mod B
10 5 2 0 0 -10 5 -2 0 0 11 5 2 1 1 -11 5 -2 -1 4 12 5 2 2 2 -12 5 -2 -2 3 13 5 2 3 3 -13 5 -2 -3 2 14 5 2 4 4 -14 5 -2 -4 1
A B A/B A rem B A mod B A B A/B A rem B A mod B 10 -5 -2 0 0 -10 -5 2 0 0 11 -5 -2 1 -4 -11 -5 2 -1 -1 12 -5 -2 2 -3 -12 -5 2 -2 -2 13 -5 -2 3 -2 -13 -5 2 -3 -3 14 -5 -2 4 -1 -14 -5 2 -4 -4
I : Integer := 1; J : Integer := 2; K : Integer := 3;
X : Real := 1.0; -- see 3.5.7 Y : Real := 2.0;
F : Fraction := 0.25; -- see 3.5.9 G : Fraction := 0.5;
Expression Value Result Type
I*J 2 same as I and J, that is, Integer
K/J 1 same as K and J, that is, Integer
K mod J 1 same as K and J, that is, Integer
X/Y 0.5 same as X and Y, that is, Real
F/2 0.125 same as F, that is, Fraction
3*F 0.75 same as F, that is, Fraction
0.75*G 0.375 universal_fixed, implicitly convertible
to any fixed point type
Fraction(F*G) 0.125 Fraction, as stated by the conversion
Real(J)*Y 4.0 Real, the type of both operands after
conversion of J
function "abs"(Right : T) return T
function "not"(Right : T) return T
function "**"(Left : T; Right : Natural) return T
function "**"(Left : T; Right : Integer'Base) return T
NOTES
type_conversion ::=
subtype_mark(expression)
| subtype_mark(name)
NOTES
Real(2*J) -- value is converted to floating point Integer(1.6) -- value is 2 Integer(-0.4) -- value is 0
type A_Form is new B_Form;
X : A_Form; Y : B_Form;
X := A_Form(Y); Y := B_Form(X); -- the reverse conversion
type Sequence is array (Integer range <>) of Integer; subtype Dozen is Sequence(1 .. 12); Ledger : array(1 .. 100) of Integer;
Sequence(Ledger) -- bounds are those of Ledger Sequence(Ledger(31 .. 42)) -- bounds are 31 and 42 Dozen(Ledger(31 .. 42)) -- bounds are those of Dozen
qualified_expression ::= subtype_mark'(expression) | subtype_mark'aggregate
NOTES
type Mask is (Fix, Dec, Exp, Signif); type Code is (Fix, Cla, Dec, Tnz, Sub);
Print (Mask'(Dec)); -- Dec is of type Mask Print (Code'(Dec)); -- Dec is of type Code
for J in Code'(Fix) .. Code'(Dec) loop ... -- qualification needed for either Fix or Dec for J in Code range Fix .. Dec loop ... -- qualification unnecessary for J in Code'(Fix) .. Dec loop ... -- qualification unnecessary for Dec
Dozen'(1 | 3 | 5 | 7 => 2, others => 0) -- see 4.6
allocator ::= new subtype_indication | new qualified_expression
NOTES
new Cell'(0, null, null) -- initialized explicitly, see 3.10.1 new Cell'(Value => 0, Succ => null, Pred => null) -- initialized explicitly new Cell -- not initialized
new Matrix(1 .. 10, 1 .. 20) -- the bounds only are given new Matrix'(1 .. 10 => (1 .. 20 => 0.0)) -- initialized explicitly
new Buffer(100) -- the discriminant only is given new Buffer'(Size => 80, Pos => 0, Value => (1 .. 80 => 'A')) -- initialized explicitly
Expr_Ptr'(new Literal) -- allocator for access-to-class-wide type, see 3.9.1 Expr_Ptr'(new Literal'(Expression with 3.5)) -- initialized explicitly
NOTES
1 + 1 -- 2 abs(-10)*3 -- 30
Kilo : constant := 1000; Mega : constant := Kilo*Kilo; -- 1_000_000 Long : constant := Float'Digits*2;
Half_Pi : constant := Pi/2; -- see 3.3.2. Deg_To_Rad : constant := Half_Pi/90; Rad_To_Deg : constant := 1.0/Deg_To_Rad; -- equivalent to 1.0/((3.14159_26536/2)/90)
sequence_of_statements ::= statement {statement}
statement ::=
{label} simple_statement | {label} compound_statement
simple_statement ::= null_statement | assignment_statement | exit_statement | goto_statement | procedure_call_statement | return_statement | entry_call_statement | requeue_statement | delay_statement | abort_statement | raise_statement | code_statement
compound_statement ::=
if_statement | case_statement
| loop_statement | block_statement
| accept_statement | select_statement
null_statement ::= null;
label ::= <<label_statement_identifier>>
statement_identifier ::= direct_name
NOTES
<<Here>> <<Ici>> <<Aqui>> <<Hier>> null;
<<After>> X := 1;
assignment_statement ::= variable_name := expression;
NOTES
Value := Max_Value - 1; Shade := Blue;
Next_Frame(F)(M, N) := 2.5; -- see 4.1.1 U := Dot_Product(V, W); -- see 6.3
Writer := (Status => Open, Unit => Printer, Line_Count => 60); -- see 3.8.1 Next_Car.all := (72074, null); -- see 3.10.1
I, J : Integer range 1 .. 10 := 5; K : Integer range 1 .. 20 := 15; ...
I := J; -- identical ranges K := J; -- compatible ranges J := K; -- will raise Constraint_Error if K > 10
A : String(1 .. 31); B : String(3 .. 33); ...
A := B; -- same number of components
A(1 .. 9) := "tar sauce"; A(4 .. 12) := A(1 .. 9); -- A(1 .. 12) = "tartar sauce"
NOTES
if_statement ::=
if condition then
sequence_of_statements
{elsif condition then
sequence_of_statements}
[else
sequence_of_statements]
end if;
condition ::= boolean_expression
if Month = December and Day = 31 then Month := January; Day := 1; Year := Year + 1; end if;
if Line_Too_Short then raise Layout_Error; elsif Line_Full then New_Line; Put(Item); else Put(Item); end if;
if My_Car.Owner.Vehicle /= My_Car then -- see 3.10.1 Report ("Incorrect data"); end if;
case_statement ::=
case expression is
case_statement_alternative
{case_statement_alternative}
end case;
case_statement_alternative ::=
when discrete_choice_list =>
sequence_of_statements
NOTES
case Sensor is when Elevation => Record_Elevation(Sensor_Value); when Azimuth => Record_Azimuth (Sensor_Value); when Distance => Record_Distance (Sensor_Value); when others => null; end case;
case Today is when Mon => Compute_Initial_Balance; when Fri => Compute_Closing_Balance; when Tue .. Thu => Generate_Report(Today); when Sat .. Sun => null; end case;
case Bin_Number(Count) is
when 1 => Update_Bin(1);
when 2 => Update_Bin(2);
when 3 | 4 =>
Empty_Bin(1);
Empty_Bin(2);
when others => raise Error;
end case;
loop_statement ::=
[loop_statement_identifier:]
[iteration_scheme] loop
sequence_of_statements
end loop [loop_identifier];
iteration_scheme ::= while condition | for loop_parameter_specification
loop_parameter_specification ::= defining_identifier in [reverse] discrete_subtype_definition
NOTES
for J in reverse 1 .. 0 for J in 0 .. 1
loop Get(Current_Character); exit when Current_Character = '*'; end loop;
while Bid(N).Price < Cut_Off.Price loop Record_Bid(Bid(N).Price); N := N + 1; end loop;
for J in Buffer'Range loop -- works even with a null range
if Buffer(J) /= Space then
Put(Buffer(J));
end if;
end loop;
Summation: while Next /= Head loop -- see 3.10.1 Sum := Sum + Next.Value; Next := Next.Succ; end loop Summation;
block_statement ::=
[block_statement_identifier:]
[declare
declarative_part]
begin
handled_sequence_of_statements
end [block_identifier];
Swap:
declare
Temp : Integer;
begin
Temp := V; V := U; U := Temp;
end Swap;
exit_statement ::= exit [loop_name] [when condition];
NOTES
for N in 1 .. Max_Num_Items loop Get_New_Item(New_Item); Merge_Item(New_Item, Storage_File); exit when New_Item = Terminal_Item; end loop;
Main_Cycle:
loop
-- initial statements
exit Main_Cycle when Found;
-- final statements
end loop Main_Cycle;
goto_statement ::= goto label_name;
NOTES
<<Sort>>
for I in 1 .. N-1 loop
if A(I) > A(I+1) then
Exchange(A(I), A(I+1));
goto Sort;
end if;
end loop;
--- The Detailed Node Listing ---
subprogram_declaration ::= subprogram_specification;
abstract_subprogram_declaration ::= subprogram_specification is abstract;
subprogram_specification ::=
procedure defining_program_unit_name parameter_profile
| function defining_designator parameter_and_result_profile
designator ::= [parent_unit_name . ]identifier | operator_symbol
defining_designator ::= defining_program_unit_name | defining_operator_symbol
defining_program_unit_name ::= [parent_unit_name . ]defining_identifier
operator_symbol ::= string_literal
defining_operator_symbol ::= operator_symbol
parameter_profile ::= [formal_part]
parameter_and_result_profile ::= [formal_part] return subtype_mark
formal_part ::=
(parameter_specification {; parameter_specification{)
parameter_specification ::=
defining_identifier_list : mode subtype_mark
[:= default_expression]
| defining_identifier_list : access_definition
[:= default_expression]
mode ::= [in] | in out | out
NOTES
procedure Traverse_Tree; procedure Increment(X : in out Integer); procedure Right_Indent(Margin : out Line_Size); -- see 3.5.4 procedure Switch(From, To : in out Link); -- see 3.10.1
function Random return Probability; -- see 3.5.7
function Min_Cell(X : Link) return Cell; -- see 3.10.1 function Next_Frame(K : Positive) return Frame; -- see 3.10 function Dot_Product(Left, Right : Vector) return Real; -- see 3.6
function "*"(Left, Right : Matrix) return Matrix; -- see 3.6
procedure Print_Header (Pages : in Natural; Header : in Line := (1 .. Line'Last => ' '); -- see 3.6 Center : in Boolean := True);
NOTES
subprogram_body ::=
subprogram_specification is
declarative_part
begin
handled_sequence_of_statements
end [designator];
procedure Push(E : in Element_Type; S : in out Stack) is
begin
if S.Index = S.Size then
raise Stack_Overflow;
else
S.Index := S.Index + 1;
S.Space(S.Index) := E;
end if;
end Push;
function Dot_Product(Left, Right : Vector) return Real is
Sum : Real := 0.0;
begin
Check(Left'First = Right'First and Left'Last = Right'Last);
for J in Left'Range loop
Sum := Sum + Left(J)*Right(J);
end loop;
return Sum;
end Dot_Product;
pragma Inline(name {, name{);
NOTES
procedure_call_statement ::=
procedure_name;
| procedure_prefix actual_parameter_part;
function_call ::=
function_name
| function_prefix actual_parameter_part
actual_parameter_part ::=
(parameter_association {, parameter_association{)
parameter_association ::= [formal_parameter_selector_name =>] explicit_actual_parameter
explicit_actual_parameter ::= expression | variable_name
Traverse_Tree; -- see 6.1 Print_Header(128, Title, True); -- see 6.1
Switch(From => X, To => Next); -- see 6.1. Print_Header(128, Header => Title, Center => True); -- see 6.1. Print_Header(Header => Title, Center => True, Pages => 128); -- see 6.1.
Dot_Product(U, V) -- see 6.1, and 6.3. Clock -- see 9.6. F.all -- presuming F is of an access-to-subprogram type -- see 3.10.
procedure Activate(Process : in Process_Name;
After : in Process_Name := No_Process;
Wait : in Duration := 0.0;
Prior : in Boolean := False);
procedure Pair(Left, Right : in Person_Name := new Person); -- see 3.10.1.
Activate(X); Activate(X, After => Y); Activate(X, Wait => 60.0, Prior => True); Activate(X, Y, 10.0, False);
Pair; Pair(Left => new Person, Right => new Person);
NOTES
procedure Put(X : in Integer); procedure Put(X : in String);
procedure Set(Tint : in Color); procedure Set(Signal : in Light);
Put(28);
Put("no possible ambiguity here");
Set(Tint => Red); Set(Signal => Red); Set(Color'(Red));
-- Set(Red) would be ambiguous since Red may -- denote a value either of type Color or of type Light
return_statement ::= return [expression];
return; -- in a procedure body, entry_body, or accept_statement return Key_Value(Last_Index); -- in a function body
NOTES
function "+" (Left, Right : Matrix) return Matrix; function "+" (Left, Right : Vector) return Vector; -- assuming that A, B, and C are of the type Vector -- the following two statements are equivalent: A := B + C; A := "+"(B, C);
--- The Detailed Node Listing ---
package_declaration ::= package_specification;
package_specification ::=
package defining_program_unit_name is
{basic_declarative_item}
[private
{basic_declarative_item}]
end [[parent_unit_name.]identifier]
NOTES
package Rational_Numbers is
type Rational is
record
Numerator : Integer;
Denominator : Positive;
end record;
function "="(X,Y : Rational) return Boolean;
function "/" (X,Y : Integer) return Rational; -- to construct a rational number
function "+" (X,Y : Rational) return Rational; function "-" (X,Y : Rational) return Rational; function "*" (X,Y : Rational) return Rational; function "/" (X,Y : Rational) return Rational; end Rational_Numbers;
package_body ::=
package body defining_program_unit_name is
declarative_part
[begin
handled_sequence_of_statements]
end [[parent_unit_name.]identifier];
NOTES
package body Rational_Numbers is
procedure Same_Denominator (X,Y : in out Rational) is
begin
-- reduces X and Y to the same denominator:
...
end Same_Denominator;
function "="(X,Y : Rational) return Boolean is
U : Rational := X;
V : Rational := Y;
begin
Same_Denominator (U,V);
return U.Numerator = V.Numerator;
end "=";
function "/" (X,Y : Integer) return Rational is
begin
if Y > 0 then
return (Numerator => X, Denominator => Y);
else
return (Numerator => -X, Denominator => -Y);
end if;
end "/";
function "+" (X,Y : Rational) return Rational is ... end "+"; function "-" (X,Y : Rational) return Rational is ... end "-"; function "*" (X,Y : Rational) return Rational is ... end "*"; function "/" (X,Y : Rational) return Rational is ... end "/";
end Rational_Numbers;
private_type_declaration ::=
type defining_identifier [discriminant_part] is
[[abstract] tagged] [limited] private;
private_extension_declaration ::=
type defining_identifier [discriminant_part] is
[abstract] new ancestor_subtype_indication with private;
NOTES
type Key is private; type File_Name is limited private;
type List is new Ada.Finalization.Controlled with private;
Denotes the class-wide subtype corresponding to the full view of S. This attribute is allowed only from the beginning of the private part in which the full view is declared, until the declaration of the full view. After the full view, the Class attribute of the full view can be used.
NOTES
package Key_Manager is type Key is private; Null_Key : constant Key; -- a deferred constant declaration, see 7.4 procedure Get_Key(K : out Key); function "<" (X, Y : Key) return Boolean; private type Key is new Natural; Null_Key : constant Key := Key'First; end Key_Manager;
package body Key_Manager is
Last_Key : Key := Null_Key;
procedure Get_Key(K : out Key) is
begin
Last_Key := Last_Key + 1;
K := Last_Key;
end Get_Key;
function "<" (X, Y : Key) return Boolean is
begin
return Natural(X) < Natural(Y);
end "<";
end Key_Manager;
NOTES
NOTES
Null_Key : constant Key; -- see 7.3.1
CPU_Identifier : constant String(1..8); pragma Import(Assembler, CPU_Identifier, Link_Name => "CPU_ID"); -- see B.1
NOTES
package IO_Package is type File_Name is limited private;
procedure Open (F : in out File_Name);
procedure Close(F : in out File_Name);
procedure Read (F : in File_Name; Item : out Integer);
procedure Write(F : in File_Name; Item : in Integer);
private
type File_Name is
limited record
Internal_Name : Integer := 0;
end record;
end IO_Package;
package body IO_Package is Limit : constant := 200; type File_Descriptor is record ... end record; Directory : array (1 .. Limit) of File_Descriptor; ... procedure Open (F : in out File_Name) is ... end; procedure Close(F : in out File_Name) is ... end; procedure Read (F : in File_Name; Item : out Integer) is ... end; procedure Write(F : in File_Name; Item : in Integer) is ... end; begin ... end IO_Package;
NOTES
package Ada.Finalization is
pragma Preelaborate(Finalization);
type Controlled is abstract tagged private;
procedure Initialize(Object : in out Controlled);
procedure Adjust (Object : in out Controlled);
procedure Finalize (Object : in out Controlled);
type Limited_Controlled is abstract tagged limited private;
procedure Initialize(Object : in out Limited_Controlled);
procedure Finalize (Object : in out Limited_Controlled);
private
... -- not specified by the language
end Ada.Finalization;
NOTES
--- The Detailed Node Listing ---
NOTES
NOTES
NOTES
use_clause ::= use_package_clause | use_type_clause
use_package_clause ::= use package_name {, package_name};
use_type_clause ::= use type subtype_mark {, subtype_mark};
with Ada.Calendar; use Ada;
Example of a use type clause:
use type Rational_Numbers.Rational; -- see 7.1 Two_Thirds: Rational_Numbers.Rational := 2/3;
renaming_declaration ::=
object_renaming_declaration
| exception_renaming_declaration
| package_renaming_declaration
| subprogram_renaming_declaration
| generic_renaming_declaration
NOTES
subtype Mode is Ada.Text_IO.File_Mode;
object_renaming_declaration ::= defining_identifier : subtype_mark renames object_name;
declare L : Person renames Leftmost_Person; -- see 3.10.1 begin L.Age := L.Age + 1; end;
exception_renaming_declaration ::= defining_identifier : exception renames exception_name;
EOF : exception renames Ada.IO_Exceptions.End_Error; -- see A.13
package_renaming_declaration ::= package defining_program_unit_name renames package_name;
package TM renames Table_Manager;
subprogram_renaming_declaration ::= subprogram_specification renames callable_entity_name;
NOTES
procedure My_Write(C : in Character) renames Pool(K).Write; -- see 4.1.3
function Real_Plus(Left, Right : Real ) return Real renames "+"; function Int_Plus (Left, Right : Integer) return Integer renames "+";
function Rouge return Color renames Red; -- see 3.5.1 function Rot return Color renames Red; function Rosso return Color renames Rouge;
function Next(X : Color) return Color renames Color'Succ; -- see 3.5.1
function "*" (X,Y : Vector) return Real renames Dot_Product; -- see 6.1
function Minimum(L : Link := Head) return Cell renames Min_Cell; -- see 6.1
generic_renaming_declaration ::=
generic package defining_program_unit_name renames
generic_package_name;
| generic procedure defining_program_unit_name renames
generic_procedure_name;
| generic function defining_program_unit_name renames
generic_function_name;
NOTES
generic package Enum_IO renames Ada.Text_IO.Enumeration_IO; -- see A.10.10
NOTES
NOTES
--- The Detailed Node Listing ---
task_type_declaration ::=
task type defining_identifier [known_discriminant_part]
[is task_definition];
single_task_declaration ::= task defining_identifier [is task_definition];
task_definition ::=
{task_item}
[ private
{task_item}]
end [task_identifier]
task_item ::= entry_declaration | representation_clause
task_body ::=
task body defining_identifier is
declarative_part
begin
handled_sequence_of_statements
end [task_identifier];
NOTES
task type Server is entry Next_Work_Item(WI : in Work_Item); entry Shut_Down; end Server;
task type Keyboard_Driver(ID : Keyboard_ID := New_ID) is entry Read (C : out Character); entry Write(C : in Character); end Keyboard_Driver;
task Controller is entry Request(Level)(D : Item); -- a family of entries end Controller;
task Parser is entry Next_Lexeme(L : in Lexical_Element); entry Next_Action(A : out Parser_Action); end;
task User; -- has no entries
Agent : Server; Teletype : Keyboard_Driver(TTY_ID); Pool : array(1 .. 10) of Keyboard_Driver;
type Keyboard is access Keyboard_Driver; Terminal : Keyboard := new Keyboard_Driver(Term_ID);
NOTES
procedure P is A, B : Server; -- elaborate the task objects A, B C : Server; -- elaborate the task object C begin -- the tasks A, B, C are activated together -- before the first statement ... end;
NOTES
declare type Global is access Server; -- see 9.1 A, B : Server; G : Global; begin -- activation of A and B declare type Local is access Server; X : Global := new Server; -- activation of X.all L : Local := new Server; -- activation of L.all C : Server; begin -- activation of C G := X; -- both G and X designate the same task object ... end; -- await termination of C and L.all (but not X.all) ... end; -- await termination of A, B, and G.all
protected_type_declaration ::=
protected type defining_identifier [known_discriminant_part] is
protected_definition;
single_protected_declaration ::= protected defining_identifier is protected_definition;
protected_definition ::=
{ protected_operation_declaration }
[ private
{ protected_element_declaration } ]
end [protected_identifier]
protected_operation_declaration ::=
subprogram_declaration
| entry_declaration
| representation_clause
protected_element_declaration ::= protected_operation_declaration | component_declaration
protected_body ::=
protected body defining_identifier is
{ protected_operation_item }
end [protected_identifier];
protected_operation_item ::=
subprogram_declaration
| subprogram_body
| entry_body
| representation_clause
NOTES
protected type Resource is entry Seize; procedure Release; private Busy : Boolean := False; end Resource;
protected body Resource is
entry Seize when not Busy is
begin
Busy := True;
end Seize;
procedure Release is
begin
Busy := False;
end Release;
end Resource;
protected Shared_Array is -- Index, Item, and Item_Array are global types function Component (N : in Index) return Item; procedure Set_Component(N : in Index; E : in Item); private Table : Item_Array(Index) := (others => Null_Item); end Shared_Array;
protected body Shared_Array is
function Component(N : in Index) return Item is
begin
return Table(N);
end Component;
procedure Set_Component(N : in Index; E : in Item) is
begin
Table(N) := E;
end Set_Component;
end Shared_Array;
Control : Resource; Flags : array(1 .. 100) of Resource;
NOTES
Shared_Array.Set_Component(N, E); E := Shared_Array.Component(M); Control.Release;
entry_declaration ::=
entry defining_identifier [(discrete_subtype_definition)]
parameter_profile;
accept_statement ::=
accept entry_direct_name [(entry_index)] parameter_profile
[do handled_sequence_of_statements
end [entry_identifier]];
entry_index ::= expression
entry_body ::=
entry defining_identifier entry_body_formal_part entry_barrier is
declarative_part
begin
handled_sequence_of_statements
end [entry_identifier];
entry_body_formal_part ::= [(entry_index_specification)] parameter_profile
entry_barrier ::= when condition
entry_index_specification ::= for defining_identifier in discrete_subtype_definition
NOTES
entry Read(V : out Item); entry Seize; entry Request(Level)(D : Item); -- a family of entries
accept Shut_Down;
accept Read(V : out Item) do V := Local_Item; end Read;
accept Request(Low)(D : Item) do ... end Request;
entry_call_statement ::= entry_name [actual_parameter_part];
NOTES
Agent.Shut_Down; -- see 9.1 Parser.Next_Lexeme(E); -- see 9.1 Pool(5).Read(Next_Char); -- see 9.1 Controller.Request(Low)(Some_Item); -- see 9.1 Flags(3).Seize; -- see 9.4
requeue_statement ::= requeue entry_name [with abort];
NOTES
requeue Request(Medium) with abort; -- requeue on a member of an entry family -- of the current task, see 9.1
requeue Flags(I).Seize; -- requeue on an entry of an array -- component, see 9.4
delay_statement ::= delay_until_statement | delay_relative_statement
delay_until_statement ::= delay until delay_expression;
delay_relative_statement ::= delay delay_expression;
package Ada.Calendar is type Time is private;
subtype Year_Number is Integer range 1901 .. 2099; subtype Month_Number is Integer range 1 .. 12; subtype Day_Number is Integer range 1 .. 31; subtype Day_Duration is Duration range 0.0 .. 86_400.0;
function Clock return Time;
function Year (Date : Time) return Year_Number; function Month (Date : Time) return Month_Number; function Day (Date : Time) return Day_Number; function Seconds(Date : Time) return Day_Duration;
procedure Split (Date : in Time;
Year : out Year_Number;
Month : out Month_Number;
Day : out Day_Number;
Seconds : out Day_Duration);
function Time_Of(Year : Year_Number;
Month : Month_Number;
Day : Day_Number;
Seconds : Day_Duration := 0.0)
return Time;
function "+" (Left : Time; Right : Duration) return Time; function "+" (Left : Duration; Right : Time) return Time; function "-" (Left : Time; Right : Duration) return Time; function "-" (Left : Time; Right : Time) return Duration;
function "<" (Left, Right : Time) return Boolean; function "<="(Left, Right : Time) return Boolean; function ">" (Left, Right : Time) return Boolean; function ">="(Left, Right : Time) return Boolean;
Time_Error : exception;
private ... -- not specified by the language end Ada.Calendar;
NOTES
delay 3.0; -- delay 3.0 seconds
declare
use Ada.Calendar;
Next_Time : Time := Clock + Period;
-- Period is a global constant of type Duration
begin
loop -- repeated every Period seconds
delay until Next_Time;
... -- perform some actions
Next_Time := Next_Time + Period;
end loop;
end;
select_statement ::=
selective_accept
| timed_entry_call
| conditional_entry_call
| asynchronous_select
select accept Driver_Awake_Signal; or delay 30.0*Seconds; Stop_The_Train; end select;
selective_accept ::=
select
[guard]
select_alternative
{ or
[guard]
select_alternative }
[ else
sequence_of_statements ]
end select;
guard ::= when condition =>
select_alternative ::=
accept_alternative
| delay_alternative
| terminate_alternative
accept_alternative ::= accept_statement [sequence_of_statements]
delay_alternative ::= delay_statement [sequence_of_statements]
terminate_alternative ::= terminate;
NOTES
task body Server is
Current_Work_Item : Work_Item;
begin
loop
select
accept Next_Work_Item(WI : in Work_Item) do
Current_Work_Item := WI;
end;
Process_Work_Item(Current_Work_Item);
or
accept Shut_Down;
exit; -- Premature shut down requested
or
terminate; -- Normal shutdown at end of scope
end select;
end loop;
end Server;
timed_entry_call ::=
select
entry_call_alternative
or
delay_alternative
end select;
entry_call_alternative ::= entry_call_statement [sequence_of_statements]
select Controller.Request(Medium)(Some_Item); or delay 45.0; -- controller too busy, try something else end select;
conditional_entry_call ::=
select
entry_call_alternative
else
sequence_of_statements
end select;
NOTES
procedure Spin(R : in Resource) is
begin
loop
select
R.Seize;
return;
else
null; -- busy waiting
end select;
end loop;
end;
asynchronous_select ::=
select
triggering_alternative
then abort
abortable_part
end select;
triggering_alternative ::= triggering_statement [sequence_of_statements]
triggering_statement ::= entry_call_statement | delay_statement
abortable_part ::= sequence_of_statements
loop
select
Terminal.Wait_For_Interrupt;
Put_Line("Interrupted");
then abort
-- This will be abandoned upon terminal interrupt
Put_Line("-> ");
Get_Line(Command, Last);
Process_Command(Command(1..Last));
end select;
end loop;
select
delay 5.0;
Put_Line("Calculation does not converge");
then abort
-- This calculation should finish in 5.0 seconds;
-- if not, it is assumed to diverge.
Horribly_Complicated_Recursive_Function(X, Y);
end select;
abort_statement ::= abort task_name {, task_name};
NOTES
Yields the value True when the task denoted by T is callable, and False otherwise; a task is callable unless it is completed or abnormal. The value of this attribute is of the predefined type Boolean.
Yields the value True if the task denoted by T is terminated, and False otherwise. The value of this attribute is of the predefined type Boolean.
Yields the number of calls presently queued on the entry E of the current instance of the unit. The value of this attribute is of the type universal_integer.
NOTES
task Producer;
task body Producer is
Char : Character;
begin
loop
... -- produce the next character Char
Buffer.Write(Char);
exit when Char = ASCII.EOT;
end loop;
end Producer;
task Consumer;
task body Consumer is
Char : Character;
begin
loop
Buffer.Read(Char);
exit when Char = ASCII.EOT;
... -- consume the character Char
end loop;
end Consumer;
protected Buffer is entry Read (C : out Character); entry Write(C : in Character); private Pool : String(1 .. 100); Count : Natural := 0; In_Index, Out_Index : Positive := 1; end Buffer;
protected body Buffer is
entry Write(C : in Character)
when Count < Pool'Length is
begin
Pool(In_Index) := C;
In_Index := (In_Index mod Pool'Length) + 1;
Count := Count + 1;
end Write;
entry Read(C : out Character)
when Count > 0 is
begin
C := Pool(Out_Index);
Out_Index := (Out_Index mod Pool'Length) + 1;
Count := Count - 1;
end Read;
end Buffer;
--- The Detailed Node Listing ---
compilation ::= {compilation_unit}
compilation_unit ::=
context_clause library_item
| context_clause subunit
library_item ::= [private] library_unit_declaration | library_unit_body | [private] library_unit_renaming_declaration
library_unit_declaration ::=
subprogram_declaration | package_declaration
| generic_declaration | generic_instantiation
library_unit_renaming_declaration ::=
package_renaming_declaration
| generic_renaming_declaration
| subprogram_renaming_declaration
library_unit_body ::= subprogram_body | package_body
parent_unit_name ::= name
NOTES
package Rational_Numbers.IO is -- public child of Rational_Numbers, see 7.1 procedure Put(R : in Rational); procedure Get(R : out Rational); end Rational_Numbers.IO;
private procedure Rational_Numbers.Reduce(R : in out Rational); -- private child of Rational_Numbers
with Rational_Numbers.Reduce; -- refer to a private child package body Rational_Numbers is ... end Rational_Numbers;
with Rational_Numbers.IO; use Rational_Numbers; with Ada.Text_io; -- see A.10 procedure Main is -- a root library procedure R : Rational; begin R := 5/3; -- construct a rational number, see 7.1 Ada.Text_IO.Put("The answer is: "); IO.Put(R); Ada.Text_IO.New_Line; end Main;
with Rational_Numbers.IO; package Rational_IO renames Rational_Numbers.IO; -- a library unit renaming declaration
context_clause ::= {context_item}
context_item ::= with_clause | use_clause
with_clause ::= with library_unit_name {, library_unit_name};
NOTES
body_stub ::=
subprogram_body_stub
| package_body_stub
| task_body_stub
| protected_body_stub
subprogram_body_stub ::= subprogram_specification is separate;
package_body_stub ::= package body defining_identifier is separate;
task_body_stub ::= task body defining_identifier is separate;
protected_body_stub ::= protected body defining_identifier is separate;
subunit ::= separate (parent_unit_name) proper_body
NOTES
package Parent is
procedure Inner;
end Parent;
with Ada.Text_IO;
package body Parent is
Variable : String := "Hello, there.";
procedure Inner is
begin
Ada.Text_IO.Put_Line(Variable);
end Inner;
end Parent;
package body Parent is
Variable : String := "Hello, there.";
procedure Inner is separate;
end Parent;
with Ada.Text_IO;
separate(Parent)
procedure Inner is
begin
Ada.Text_IO.Put_Line(Variable);
end Inner;
NOTES
task Environment_Task;
task body Environment_Task is
... (1) -- The environment declarative_part
-- (that is, the sequence of library_items) goes here.
begin
... (2) -- Call the main subprogram, if there is one.
end Environment_Task;
NOTES
pragma Preelaborate[(library_unit_name)];
pragma Pure[(library_unit_name)];
pragma Elaborate(library_unit_name{, library_unit_name});
pragma Elaborate_All(library_unit_name{, library_unit_name});
pragma Elaborate_Body[(library_unit_name)];
NOTES
--- The Detailed Node Listing ---
Singular : exception; Error : exception; Overflow, Underflow : exception;
handled_sequence_of_statements ::=
sequence_of_statements
[exception
exception_handler
{exception_handler}]
exception_handler ::=
when [choice_parameter_specification:]
exception_choice {| exception_choice} =>
sequence_of_statements
choice_parameter_specification ::= defining_identifier
exception_choice ::= exception_name | others
begin Open(File, In_File, "input.txt"); -- see A.8.2 exception when E : Name_Error => Put("Cannot open input file : "); Put_Line(Exception_Message(E)); -- see 11.4.1 raise; end;
raise_statement ::= raise [exception_name];
raise Ada.IO_Exceptions.Name_Error; -- see A.13
raise; -- re-raise the current exception
NOTES
package Ada.Exceptions is
type Exception_Id is private;
Null_Id : constant Exception_Id;
function Exception_Name(Id : Exception_Id) return String;
type Exception_Occurrence is limited private;
type Exception_Occurrence_Access is
access all Exception_Occurrence;
Null_Occurrence : constant Exception_Occurrence;
procedure Raise_Exception
(E : in Exception_Id;
Message : in String := "");
function Exception_Message(X : Exception_Occurrence)
return String;
procedure Reraise_Occurrence(X : in Exception_Occurrence);
function Exception_Identity(X : Exception_Occurrence)
return Exception_Id;
function Exception_Name(X : Exception_Occurrence)
return String;
-- Same as Exception_Name(Exception_Identity(X)).
function Exception_Information(X : Exception_Occurrence)
return String;
procedure Save_Occurrence(Target : out Exception_Occurrence;
Source : in Exception_Occurrence);
function Save_Occurrence(Source : Exception_Occurrence)
return Exception_Occurrence_Access;
private
... -- not specified by the language
end Ada.Exceptions;
E'Identity returns the unique identity of the exception. The type of this attribute is Exception_Id.
with Ada.Exceptions;
use Ada;
package File_System is
type File_Handle is limited private;
File_Not_Found : exception;
procedure Open(F : in out File_Handle; Name : String);
-- raises File_Not_Found if named file does not exist
End_Of_File : exception;
procedure Read(F : in out File_Handle; Data : out Data_Type);
-- raises End_Of_File if the file is not open
... end File_System;
package body File_System is
procedure Open(F : in out File_Handle; Name : String) is
begin
if File_Exists(Name) then
...
else
Exceptions.Raise_Exception
(File_Not_Found'Identity,
"File not found: " & Name & ".");
end if;
end Open;
procedure Read(F : in out File_Handle; Data : out Data_Type) is
begin
if F.Current_Position <= F.Last_Position then
...
else
raise End_Of_File;
end if;
end Read;
...
end File_System;
with Ada.Text_IO;
with Ada.Exceptions;
with File_System; use File_System;
use Ada;
procedure Main is
begin
... -- call operations in File_System
exception
when End_Of_File =>
Close(Some_File);
when Not_Found_Error : File_Not_Found =>
Text_IO.Put_Line
(Exceptions.Exception_Message(Not_Found_Error));
when The_Error : others =>
Text_IO.Put_Line("Unknown error:");
if Verbosity_Desired then
Text_IO.Put_Line(Exceptions.Exception_Information
(The_Error));
else
Text_IO.Put_Line(Exceptions.Exception_Name
(The_Error));
Text_IO.Put_Line(Exceptions.Exception_Message
(The_Error));
end if;
raise;
end Main;
pragma Suppress(identifier [, [On =>] name]);
When evaluating a dereference (explicit or implicit), check that the value of the name is not null. When passing an actual parameter to a formal access parameter, check that the value of the actual parameter is not null.
Check that the discriminants of a composite value have the values imposed by a discriminant constraint. Also, when accessing a record component, check that it exists for the current discriminant values.
Check that the second operand is not zero for the operations /, rem and mod.
Check that the bounds of an array value are equal to the corresponding bounds of an index constraint. Also, when accessing a component of an array object, check for each dimension that the given index value belongs to the range defined by the bounds of the array object. Also, when accessing a slice of an array object, check that the given discrete range is compatible with the range defined by the bounds of the array object.
Check that two arrays have matching components, in the case of array subtype conversions, and logical operators for arrays of boolean components.
Check that a scalar value is within the base range of its type, in cases where the implementation chooses to raise an exception instead of returning the correct mathematical result.
Check that a scalar value satisfies a range constraint. Also, for the elaboration of a subtype_indication, check that the constraint (if present) is compatible with the subtype denoted by the subtype_mark. Also, for an aggregate, check that an index or discriminant value belongs to the corresponding subtype. Also, check that when the result of an operation yields an array, the value of each component belongs to the component subtype.
Check that operand tags in a dispatching call are all equal. Check for the correct tag on tagged type conversions, for an assignment_statement, and when returning a tagged limited object from a function.
When a subprogram or protected entry is called, a task activation is accomplished, or a generic instantiation is elaborated, check that the body of the corresponding unit has already been elaborated.
Check the accessibility level of an entity or view.
Check that evaluation of an allocator does not require more space than is available for a storage pool. Check that the space available for a task or subprogram has not been exceeded.
Represents the union of all checks; suppressing All_Checks suppresses all checks.
NOTES
pragma Suppress(Range_Check); pragma Suppress(Index_Check, On => Table);
NOTES
--- The Detailed Node Listing ---
generic_declaration ::= generic_subprogram_declaration | generic_package_declaration
generic_subprogram_declaration ::= generic_formal_part subprogram_specification;
generic_package_declaration ::= generic_formal_part package_specification;
generic_formal_part ::=
generic {generic_formal_parameter_declaration | use_clause}
generic_formal_parameter_declaration ::=
formal_object_declaration
| formal_type_declaration
| formal_subprogram_declaration
| formal_package_declaration
NOTES
generic -- parameterless
generic
Size : Natural; -- formal object
generic Length : Integer := 200; -- formal object with a default expression
Area : Integer := Length*Length; -- formal object with a default expression
generic type Item is private; -- formal type type Index is (<>); -- formal type type Row is array(Index range <>) of Item; -- formal type with function "<"(X, Y : Item) return Boolean; -- formal subprogram
generic type Elem is private; procedure Exchange(U, V : in out Elem);
generic type Item is private; with function "*"(U, V : Item) return Item is <>; function Squaring(X : Item) return Item;
generic type Item is private; type Vector is array (Positive range <>) of Item; with function Sum(X, Y : Item) return Item; package On_Vectors is function Sum (A, B : Vector) return Vector; function Sigma(A : Vector) return Item; Length_Error : exception; end On_Vectors;
NOTES
procedure Exchange(U, V : in out Elem) is -- see 12.1 T : Elem; -- the generic formal type begin T := U; U := V; V := T; end Exchange;
function Squaring(X : Item) return Item is -- see 12.1 begin return X*X; -- the formal operator "*" end Squaring;
package body On_Vectors is -- see 12.1
function Sum(A, B : Vector) return Vector is
Result : Vector(A'Range); -- the formal type Vector
Bias : constant Integer := B'First - A'First;
begin
if A'Length /= B'Length then
raise Length_Error;
end if;
for N in A'Range loop
Result(N) := Sum(A(N), B(N + Bias));
-- the formal function Sum
end loop;
return Result;
end Sum;
function Sigma(A : Vector) return Item is
Total : Item := A(A'First); -- the formal type Item
begin
for N in A'First + 1 .. A'Last loop
Total := Sum(Total, A(N)); -- the formal function Sum
end loop;
return Total;
end Sigma;
end On_Vectors;
generic_instantiation ::=
package defining_program_unit_name is
new generic_package_name [generic_actual_part];
| procedure defining_program_unit_name is
new generic_procedure_name [generic_actual_part];
| function defining_designator is
new generic_function_name [generic_actual_part];
generic_actual_part ::=
(generic_association {, generic_association})
generic_association ::=
[generic_formal_parameter_selector_name =>]
explicit_generic_actual_parameter
explicit_generic_actual_parameter ::= expression | variable_name | subprogram_name | entry_name | subtype_mark | package_instance_name
NOTES
procedure Swap is new Exchange(Elem => Integer); procedure Swap is new Exchange(Character); -- Swap is overloaded function Square is new Squaring(Integer); -- "*" of Integer used by default function Square is new Squaring (Item => Matrix, "*" => Matrix_Product); function Square is new Squaring (Matrix, Matrix_Product); -- same as previous
package Int_Vectors is new On_Vectors(Integer, Table, "+");
Swap(A, B); A := Square(A);
T : Table(1 .. 5) := (10, 20, 30, 40, 50); N : Integer := Int_Vectors.Sigma(T); -- 150 (see ``Generic Bodies'', for the body of Sigma)
use Int_Vectors; M : Integer := Sigma(T); -- 150
formal_object_declaration ::=
defining_identifier_list : mode subtype_mark
[:= default_expression];
NOTES
formal_type_declaration ::=
type defining_identifier[discriminant_part] is
formal_type_definition;
formal_type_definition ::=
formal_private_type_definition
| formal_derived_type_definition
| formal_discrete_type_definition
| formal_signed_integer_type_definition
| formal_modular_type_definition
| formal_floating_point_definition
| formal_ordinary_fixed_point_definition
| formal_decimal_fixed_point_definition
| formal_array_type_definition
| formal_access_type_definition
NOTES
type Item is private; type Buffer(Length : Natural) is limited private;
type Enum is (<>); type Int is range <>; type Angle is delta <>; type Mass is digits <>;
type Table is array (Enum) of Item;
generic type Rank is range <>; First : Rank := Rank'First; Second : Rank := First + 1; -- the operator "+" of the type Rank
formal_private_type_definition ::= [[abstract] tagged] [limited] private
formal_derived_type_definition ::= [abstract] new subtype_mark [with private]
Type Definition Determined Class limited private the class of all types private the class of all nonlimited types tagged limited private the class of all tagged types tagged private the class of all nonlimited tagged types
S'Definite yields True if the actual subtype corresponding to S is definite; otherwise it yields False. The value of this attribute is of the predefined type Boolean.
NOTES
formal_discrete_type_definition ::= (<>)
formal_signed_integer_type_definition ::= range <>
formal_modular_type_definition ::= mod <>
formal_floating_point_definition ::= digits <>
formal_ordinary_fixed_point_definition ::= delta <>
formal_decimal_fixed_point_definition ::= delta <> digits <>
NOTES
formal_array_type_definition ::= array_type_definition
-- given the generic package
generic type Item is private; type Index is (<>); type Vector is array (Index range <>) of Item; type Table is array (Index) of Item; package P is ... end P;
-- and the types
type Mix is array (Color range <>) of Boolean; type Option is array (Color) of Boolean;
-- then Mix can match Vector and Option can match Table
package R is new P(Item => Boolean, Index => Color,
Vector => Mix, Table => Option);
-- Note that Mix cannot match Table and Option cannot match Vector
formal_access_type_definition ::= access_type_definition
-- the formal types of the generic package
generic type Node is private; type Link is access Node; package P is ... end P;
-- can be matched by the actual types
type Car; type Car_Name is access Car;
type Car is
record
Pred, Succ : Car_Name;
Number : License_Number;
Owner : Person;
end record;
-- in the following generic instantiation
package R is new P(Node => Car, Link => Car_Name);
formal_subprogram_declaration ::= with subprogram_specification [is subprogram_default];
subprogram_default ::= default_name | <>
default_name ::= name
NOTES
with function "+"(X, Y : Item) return Item is <>; with function Image(X : Enum) return String is Enum'Image; with procedure Update is Default_Update;
-- given the generic procedure declaration
generic with procedure Action (X : in Item); procedure Iterate(Seq : in Item_Sequence);
-- and the procedure
procedure Put_Item(X : in Item);
-- the following instantiation is possible
procedure Put_List is new Iterate(Action => Put_Item);
formal_package_declaration ::=
with package defining_identifier is new
generic_package_name formal_package_actual_part;
formal_package_actual_part ::= (<>) | [generic_actual_part]
generic Size : Positive; type Item is private; package Stack is procedure Push(E : in Item); procedure Pop (E : out Item); Overflow, Underflow : exception; end Stack;
package body Stack is
type Table is array (Positive range <>) of Item; Space : Table(1 .. Size); Index : Natural := 0;
procedure Push(E : in Item) is
begin
if Index >= Size then
raise Overflow;
end if;
Index := Index + 1;
Space(Index) := E;
end Push;
procedure Pop(E : out Item) is
begin
if Index = 0 then
raise Underflow;
end if;
E := Space(Index);
Index := Index - 1;
end Pop;
end Stack;
package Stack_Int is new Stack(Size => 200, Item => Integer); package Stack_Bool is new Stack(100, Boolean);
Stack_Int.Push(N); Stack_Bool.Push(True);
generic
type Item is private;
package On_Stacks is
type Stack(Size : Positive) is limited private;
procedure Push(S : in out Stack; E : in Item);
procedure Pop (S : in out Stack; E : out Item);
Overflow, Underflow : exception;
private
type Table is array (Positive range <>) of Item;
type Stack(Size : Positive) is
record
Space : Table(1 .. Size);
Index : Natural := 0;
end record;
end On_Stacks;
declare package Stack_Real is new On_Stacks(Real); use Stack_Real; S : Stack(100); begin ... Push(S, 2.54); ... end;
--- The Detailed Node Listing ---
representation_clause ::=
attribute_definition_clause
| enumeration_representation_clause
| record_representation_clause
| at_clause
local_name ::=
direct_name
| direct_name'attribute_designator
| library_unit_name
pragma Pack(first_subtype_local_name);
attribute_definition_clause ::=
for local_name'attribute_designator use expression;
| for local_name'attribute_designator use name;
Denotes the address of the first of the storage elements allocated to X. For a program unit or label, this value refers to the machine code associated with the corresponding body or statement. The value of this attribute is of type System.Address.
Address may be specified for stand-alone objects and for program units via an attribute_definition_clause.
NOTES
The Address of an object that is allocated under control of the implementation is an integral multiple of the Alignment of the object (that is, the Address modulo the Alignment is zero). The offset of a record component is a multiple of the Alignment of the component. For an object that is not allocated under control of the implementation (that is, one that is imported, that is allocated by a user-defined allocator, whose Address has been specified, or is designated by an access value returned by an instance of Unchecked_Conversion), the implementation may assume that the Address is an integral multiple of its Alignment. The implementation shall not assume a stricter alignment.
The value of this attribute is of type universal_integer, and nonnegative; zero means that the object is not necessarily aligned on a storage element boundary.
Alignment may be specified for first subtypes and stand-alone objects via an attribute_definition_clause; the expression of such a clause shall be static, and its value nonnegative. If the Alignment of a subtype is specified, then the Alignment of an object of the subtype is at least as strict, unless the object's Alignment is also specified. The Alignment of an object created by an allocator is that of the designated subtype.
If an Alignment is specified for a composite subtype or object, this Alignment shall be equal to the least common multiple of any specified Alignments of the subcomponent subtypes, or an integer multiple thereof.
NOTES
Denotes the size in bits of the representation of the object. The value of this attribute is of the type universal_integer.
If S is definite, denotes the size (in bits) that the implementation would choose for the following objects of subtype S:
NOTES
Denotes the number of storage elements reserved for the task. The value of this attribute is of the type universal_integer. The Storage_Size includes the size of the task's stack, if any. The language does not specify whether or not it includes other storage associated with the task (such as the ``task control block'' used by some implementations.) If a pragma Storage_Size is given, the value of the Storage_Size attribute is at least the value specified in the pragma.
pragma Storage_Size(expression);
Denotes the size in bits of components of the type of X. The value of this attribute is of type universal_integer.
S'External_Tag denotes an external string representation for S'Tag; it is of the predefined type String. External_Tag may be specified for a specific tagged type via an attribute_definition_clause; the expression of such a clause shall be static. The default external tag representation is implementation defined. See 3.9.2, and 13.13.2.
NOTES
Byte : constant := 8; Page : constant := 2**12;
type Medium is range 0 .. 65_000; for Medium'Size use 2*Byte; for Medium'Alignment use 2; Device_Register : Medium; for Device_Register'Size use Medium'Size; for Device_Register'Address use System.Storage_Elements.To_Address(16#FFFF_0020#);
type Short is delta 0.01 range -100.0 .. 100.0; for Short'Size use 15;
for Car_Name'Storage_Size use -- specify access type's storage pool size 2000*((Car'Size/System.Storage_Unit) +1); -- approximately 2000 cars
function My_Read(Stream : access Ada.Streams.Root_Stream_Type'Class) return T; for T'Read use My_Read; -- see 13.13.2
NOTES
enumeration_representation_clause ::= for first_subtype_local_name use enumeration_aggregate;
enumeration_aggregate ::= array_aggregate
NOTES
type Mix_Code is (ADD, SUB, MUL, LDA, STA, STZ);
for Mix_Code use (ADD => 1, SUB => 2, MUL => 3, LDA => 8, STA => 24, STZ =>33);
record_representation_clause ::=
for first_subtype_local_name use
record [mod_clause]
{component_clause}
end record;
component_clause ::= component_local_name at position range first_bit .. last_bit;
position ::= static_expression
first_bit ::= static_simple_expression
last_bit ::= static_simple_expression
NOTES
Word : constant := 4; -- storage element is byte, 4 bytes per word
type State is (A,M,W,P); type Mode is (Fix, Dec, Exp, Signif);
type Byte_Mask is array (0..7) of Boolean; type State_Mask is array (State) of Boolean; type Mode_Mask is array (Mode) of Boolean;
type Program_Status_Word is
record
System_Mask : Byte_Mask;
Protection_Key : Integer range 0 .. 3;
Machine_State : State_Mask;
Interrupt_Cause : Interruption_Code;
Ilc : Integer range 0 .. 3;
Cc : Integer range 0 .. 3;
Program_Mask : Mode_Mask;
Inst_Address : Address;
end record;
for Program_Status_Word use
record
System_Mask at 0*Word range 0 .. 7;
Protection_Key at 0*Word range 10 .. 11; -- bits 8,9 unused
Machine_State at 0*Word range 12 .. 15;
Interrupt_Cause at 0*Word range 16 .. 31;
Ilc at 1*Word range 0 .. 1; -- second word
Cc at 1*Word range 2 .. 3;
Program_Mask at 1*Word range 4 .. 7;
Inst_Address at 1*Word range 8 .. 31;
end record;
for Program_Status_Word'Size use 8*System.Storage_Unit; for Program_Status_Word'Alignment use 8;
NOTES
Denotes the same value as R.C'Address - R'Address. The value of this attribute is of the type universal_integer.
Denotes the offset, from the start of the first of the storage elements occupied by C, of the first bit occupied by C. This offset is measured in bits. The first bit of a storage element is numbered zero. The value of this attribute is of the type universal_integer.
Denotes the offset, from the start of the first of the storage elements occupied by C, of the last bit occupied by C. This offset is measured in bits. The value of this attribute is of the type universal_integer.
Denotes the bit ordering for the type of S. The value of this attribute is of type System.Bit_Order. Bit_Order may be specified for specific record types via an attribute_definition_clause; the expression of such a clause shall be static.
-- Packed_Descriptor and Descriptor are two different types -- with identical characteristics, apart from their -- representation
type Descriptor is
record
-- components of a descriptor
end record;
type Packed_Descriptor is new Descriptor;
for Packed_Descriptor use
record
-- component clauses for some or for all components
end record;
-- Change of representation can now be accomplished -- by explicit type conversions:
D : Descriptor; P : Packed_Descriptor;
P := Packed_Descriptor(D); -- pack D D := Descriptor(P); -- unpack P
package System is pragma Preelaborate(System);
type Name is implementation-defined-enumeration-type; System_Name : constant Name := implementation-defined;
-- System-Dependent Named Numbers:
Min_Int : constant := root_integer'First; Max_Int : constant := root_integer'Last;
Max_Binary_Modulus : constant := implementation-defined; Max_Nonbinary_Modulus : constant := implementation-defined;
Max_Base_Digits : constant := root_real'Digits; Max_Digits : constant := implementation-defined;
Max_Mantissa : constant := implementation-defined; Fine_Delta : constant := implementation-defined;
Tick : constant := implementation-defined;
-- Storage-related Declarations:
type Address is implementation-defined; Null_Address : constant Address;
Storage_Unit : constant := implementation-defined; Word_Size : constant := implementation-defined * Storage_Unit; Memory_Size : constant := implementation-defined;
-- Address Comparison: function "<" (Left, Right : Address) return Boolean; function "<="(Left, Right : Address) return Boolean; function ">" (Left, Right : Address) return Boolean; function ">="(Left, Right : Address) return Boolean; function "=" (Left, Right : Address) return Boolean; -- function "/=" (Left, Right : Address) return Boolean; -- "/=" is implicitly defined pragma Convention(Intrinsic, "<"); ... -- and so on for all language-defined subprograms in this package
-- Other System-Dependent Declarations: type Bit_Order is (High_Order_First, Low_Order_First); Default_Bit_Order : constant Bit_Order;
-- Priority-related declarations, see D.1.: subtype Any_Priority is Integer range implementation-defined; subtype Priority is Any_Priority range Any_Priority'First .. implementation-defined; subtype Interrupt_Priority is Any_Priority range Priority'Last+1 .. Any_Priority'Last;
Default_Priority : constant Priority
:= (Priority'First + Priority'Last)/2;
private ... -- not specified by the language end System;
The smallest (most negative) value allowed for the expressions of a signed_integer_type_definition.
The largest (most positive) value allowed for the expressions of a signed_integer_type_definition.
A power of two such that it, and all lesser positive powers of two, are allowed as the modulus of a modular_type_definition.
A value such that it, and all lesser positive integers, are allowed as the modulus of a modular_type_definition.
The largest value allowed for the requested decimal precision in a floating_point_definition.
The largest value allowed for the requested decimal precision in a floating_point_definition that has no real_range_specification. Max_Digits is less than or equal to Max_Base_Digits.
The largest possible number of binary digits in the mantissa of machine numbers of a user-defined ordinary fixed point type. (The mantissa is defined in G.)
The smallest delta allowed in an ordinary_fixed_point_definition that has the real_range_specification range -1.0 .. 1.0.
A period in seconds approximating the real time interval during which the value of Calendar.Clock remains constant.
The number of bits per storage element.
The number of bits per word.
An implementation-defined value that is intended to reflect the memory size of the configuration in storage elements.
NOTES
package System.Storage_Elements is pragma Preelaborate(System.Storage_Elements);
type Storage_Offset is range implementation-defined;
subtype Storage_Count is Storage_Offset
range 0..Storage_Offset'Last;
type Storage_Element is mod implementation-defined;
for Storage_Element'Size use Storage_Unit;
type Storage_Array is array
(Storage_Offset range <>) of aliased Storage_Element;
for Storage_Array'Component_Size use Storage_Unit;
-- Address Arithmetic:
function "+"(Left : Address; Right : Storage_Offset)
return Address;
function "+"(Left : Storage_Offset; Right : Address)
return Address;
function "-"(Left : Address; Right : Storage_Offset)
return Address;
function "-"(Left, Right : Address)
return Storage_Offset;
function "mod"(Left : Address; Right : Storage_Offset)
return Storage_Offset;
-- Conversion to/from integers:
type Integer_Address is implementation-defined; function To_Address(Value : Integer_Address) return Address; function To_Integer(Value : Address) return Integer_Address;
pragma Convention(Intrinsic, "+");
-- ...and so on for all language-defined subprograms
-- declared in this package.
end System.Storage_Elements;
generic
type Object(<>) is limited private;
package System.Address_To_Access_Conversions is
pragma Preelaborate(Address_To_Access_Conversions);
type Object_Pointer is access all Object; function To_Pointer(Value : Address) return Object_Pointer; function To_Address(Value : Object_Pointer) return Address;
pragma Convention(Intrinsic, To_Pointer); pragma Convention(Intrinsic, To_Address); end System.Address_To_Access_Conversions;
code_statement ::= qualified_expression;
NOTES
M : Mask; procedure Set_Mask; pragma Inline(Set_Mask);
procedure Set_Mask is use System.Machine_Code; -- assume ``with System.Machine_Code;'' appears somewhere above begin SI_Format'(Code => SSM, B => M'Base_Reg, D => M'Disp); -- Base_Reg and Disp are implementation-defined attributes end Set_Mask;
generic type Source(<>) is limited private; type Target(<>) is limited private; function Ada.Unchecked_Conversion(S : Source) return Target; pragma Convention(Intrinsic, Ada.Unchecked_Conversion); pragma Pure(Ada.Unchecked_Conversion);
NOTES
Yields True if and only if the object denoted by X is normal and has a valid representation. The value of this attribute is of the predefined type Boolean.
NOTES
All rules and semantics that apply to X'Access, see 3.10.2, apply also to X'Unchecked_Access, except that, for the purposes of accessibility rules and checks, it is as if X were declared immediately within a library package.
NOTES
with Ada.Finalization;
with System.Storage_Elements;
package System.Storage_Pools is
pragma Preelaborate(System.Storage_Pools);
type Root_Storage_Pool is
abstract new
Ada.Finalization.Limited_Controlled with private;
procedure Allocate(
Pool : in out Root_Storage_Pool;
Storage_Address : out Address;
Size_In_Storage_Elements : in Storage_Elements.Storage_Count;
Alignment : in Storage_Elements.Storage_Count) is abstract;
procedure Deallocate(
Pool : in out Root_Storage_Pool;
Storage_Address : in Address;
Size_In_Storage_Elements : in Storage_Elements.Storage_Count;
Alignment : in Storage_Elements.Storage_Count) is abstract;
function Storage_Size(Pool : Root_Storage_Pool)
return Storage_Elements.Storage_Count is abstract;
private ... -- not specified by the language end System.Storage_Pools;
Denotes the storage pool of the type of S. The type of this attribute is Root_Storage_Pool'Class.
Yields the result of calling Storage_Size(S'Storage_Pool), which is intended to be a measure of the number of storage elements reserved for the pool. The type of this attribute is universal_integer.
NOTES
Pool_Object : Some_Storage_Pool_Type;
type T is access Designated; for T'Storage_Pool use Pool_Object;
for T2'Storage_Pool use T'Storage_Pool;
type Mark_Release_Pool_Type
(Pool_Size : Storage_Elements.Storage_Count;
Block_Size : Storage_Elements.Storage_Count)
is new Root_Storage_Pool with limited private;
...
MR_Pool : Mark_Release_Pool_Type (Pool_Size => 2000,
Block_Size => 100);
type Acc is access ...; for Acc'Storage_Pool use MR_Pool; ...
Mark(MR_Pool); ... -- Allocate objects using ``new Designated(...)''. Release(MR_Pool); -- Reclaim the storage.
Denotes the maximum value for Size_In_Storage_Elements that will be requested via Allocate for an access type whose designated subtype is S. The value of this attribute is of type universal_integer.
generic type Object(<>) is limited private; type Name is access Object; procedure Ada.Unchecked_Deallocation(X : in out Name); pragma Convention(Intrinsic, Ada.Unchecked_Deallocation); pragma Preelaborate(Ada.Unchecked_Deallocation);
procedure Free is
new Ada.Unchecked_Deallocation
(object_subtype_name, access_to_variable_subtype_name);
NOTES
pragma Controlled(first_subtype_local_name);
pragma Restrictions(restriction{, restriction});
restriction ::= restriction_identifier | restriction_parameter_identifier => expression
NOTES
package Ada.Streams is
pragma Pure(Streams);
type Root_Stream_Type is abstract tagged limited private;
type Stream_Element is mod implementation-defined;
type Stream_Element_Offset is range implementation-defined;
subtype Stream_Element_Count is
Stream_Element_Offset range 0..Stream_Element_Offset'Last;
type Stream_Element_Array is
array(Stream_Element_Offset range <>) of Stream_Element;
procedure Read(
Stream : in out Root_Stream_Type;
Item : out Stream_Element_Array;
Last : out Stream_Element_Offset) is abstract;
procedure Write(
Stream : in out Root_Stream_Type;
Item : in Stream_Element_Array) is abstract;
private ... -- not specified by the language end Ada.Streams;
NOTES
S'Write denotes a procedure with the following specification:
procedure S'Write( Stream : access Ada.Streams.Root_Stream_Type'Class; Item : in T)
S'Read denotes a procedure with the following specification:
procedure S'Read( Stream : access Ada.Streams.Root_Stream_Type'Class; Item : out T)
S'Class'Write denotes a procedure with the following specification:
procedure S'Class'Write( Stream : access Ada.Streams.Root_Stream_Type'Class; Item : in T'Class)
S'Class'Read denotes a procedure with the following specification:
procedure S'Class'Read( Stream : access Ada.Streams.Root_Stream_Type'Class; Item : out T'Class)
S'Output denotes a procedure with the following specification:
procedure S'Output( Stream : access Ada.Streams.Root_Stream_Type'Class; Item : in T)
S'Input denotes a function with the following specification:
function S'Input( Stream : access Ada.Streams.Root_Stream_Type'Class) return T
S'Class'Output denotes a procedure with the following specification:
procedure S'Class'Output( Stream : access Ada.Streams.Root_Stream_Type'Class; Item : in T'Class)
S'Class'Input denotes a function with the following specification:
function S'Class'Input( Stream : access Ada.Streams.Root_Stream_Type'Class) return T'Class
NOTES
procedure My_Write (Stream : access Ada.Streams.Root_Stream_Type'Class; Item : My_Integer'Base); for My_Integer'Write use My_Write;
Standard -- see A.1. Ada -- see A.2. Asynchronous_Task_Control -- see D.11. Calendar -- see 9.6. Characters -- see A.3.1. Handling -- see A.3.2. Latin_1 -- see A.3.3. Command_Line -- see A.15. Decimal -- see F.2. Direct_IO -- see A.8.4. Dynamic_Priorities -- see D.5. Exceptions -- see 11.4.1. Finalization -- see 7.6. Interrupts -- see C.3.2. Names -- see C.3.2. IO_Exceptions -- see A.13. Numerics -- see A.5. Complex_Elementary_Functions -- see G.1.2. Complex_Types -- see G.1.1. Discrete_Random -- see A.5.2. Elementary_Functions -- see A.5.1. Float_Random -- see A.5.2. Generic_Complex_Elementary_Functions -- see G.1.2. Generic_Complex_Types -- see G.1.1. Generic_Elementary_Functions -- see A.5.1. Real_Time -- see D.8. Sequential_IO -- see A.8.1. Storage_IO -- see A.9. Streams -- see 13.13.1. Stream_IO -- see A.12.1. Strings -- see A.4.1. Bounded -- see A.4.4. Fixed -- see A.4.3. Maps -- see A.4.2. Constants -- see A.4.6. Unbounded -- see A.4.5. Wide_Bounded -- see A.4.7. Wide_Fixed -- see A.4.7. Wide_Maps -- see A.4.7. Wide_Constants -- see A.4.7. Wide_Unbounded -- see A.4.7. Standard (...continued) Ada (...continued) Synchronous_Task_Control -- see D.10. Tags -- see 3.9. Task_Attributes -- see C.7.2. Task_Identification -- see C.7.1. Text_IO -- see A.10.1. Complex_IO -- see G.1.3. Editing -- see F.3.3. Text_Streams -- see A.12.2. Unchecked_Conversion -- see 13.9. Unchecked_Deallocation -- see 13.11.2. Wide_Text_IO -- see A.11. Complex_IO -- see G.1.3. Editing -- see F.3.4. Text_Streams -- see A.12.3. Interfaces -- see B.2. C -- see B.3. Pointers -- see B.3.2. Strings -- see B.3.1. COBOL -- see B.4. Fortran -- see B.5. System -- see 13.7. Address_To_Access_Conversions -- see 13.7.2. Machine_Code -- see 13.8. RPC -- see E.5. Storage_Elements -- see 13.7.1. Storage_Pools -- see 13.11.
--- The Detailed Node Listing ---
package Standard is pragma Pure(Standard);
type Boolean is (False, True);
-- The predefined relational operators -- for this type are as follows:
-- function "=" (Left, Right : Boolean) return Boolean; -- function "/=" (Left, Right : Boolean) return Boolean; -- function "<" (Left, Right : Boolean) return Boolean; -- function "<=" (Left, Right : Boolean) return Boolean; -- function ">" (Left, Right : Boolean) return Boolean; -- function ">=" (Left, Right : Boolean) return Boolean;
-- The predefined logical operators and the predefined -- logical negation operator are as follows:
-- function "and" (Left, Right : Boolean) return Boolean; -- function "or" (Left, Right : Boolean) return Boolean; -- function "xor" (Left, Right : Boolean) return Boolean;
-- function "not" (Right : Boolean) return Boolean;
-- The integer type root_integer is predefined. -- The corresponding universal type is universal_integer.
type Integer is range implementation-defined;
subtype Natural is Integer range 0 .. Integer'Last; subtype Positive is Integer range 1 .. Integer'Last;
-- The predefined operators for type Integer are as follows:
-- function "=" (Left, Right : Integer'Base) return Boolean; -- function "/=" (Left, Right : Integer'Base) return Boolean; -- function "<" (Left, Right : Integer'Base) return Boolean; -- function "<=" (Left, Right : Integer'Base) return Boolean; -- function ">" (Left, Right : Integer'Base) return Boolean; -- function ">=" (Left, Right : Integer'Base) return Boolean;
-- function "+" (Right : Integer'Base) return Integer'Base; -- function "-" (Right : Integer'Base) return Integer'Base; -- function "abs" (Right : Integer'Base) return Integer'Base;
-- function "+" (Left, Right : Integer'Base) -- return Integer'Base; -- function "-" (Left, Right : Integer'Base) -- return Integer'Base; -- function "*" (Left, Right : Integer'Base) -- return Integer'Base; -- function "/" (Left, Right : Integer'Base) -- return Integer'Base; -- function "rem" (Left, Right : Integer'Base) -- return Integer'Base; -- function "mod" (Left, Right : Integer'Base) -- return Integer'Base;
-- function "**"
(Left : Integer'Base;
Right : Natural) return Integer'Base;
-- The specification of each operator for the type -- root_integer, or for any additional predefined integer -- type, is obtained by replacing Integer by the name of the type -- in the specification of the corresponding operator of the type -- Integer. The right operand of the exponentiation operator -- remains as subtype Natural.
-- The floating point type root_real is predefined. -- The corresponding universal type is universal_real.
type Float is digits implementation-defined;
-- The predefined operators for this type are as follows:
-- function "=" (Left, Right : Float) return Boolean; -- function "/=" (Left, Right : Float) return Boolean; -- function "<" (Left, Right : Float) return Boolean; -- function "<=" (Left, Right : Float) return Boolean; -- function ">" (Left, Right : Float) return Boolean; -- function ">=" (Left, Right : Float) return Boolean;
-- function "+" (Right : Float) return Float; -- function "-" (Right : Float) return Float; -- function "abs" (Right : Float) return Float;
-- function "+" (Left, Right : Float) return Float; -- function "-" (Left, Right : Float) return Float; -- function "*" (Left, Right : Float) return Float; -- function "/" (Left, Right : Float) return Float;
-- function "**"
(Left : Float;
Right : Integer'Base) return Float;
-- The specification of each operator for the type root_real, -- or for any additional predefined floating point type, is -- obtained by replacing Float by the name of the type in the -- specification of the corresponding operator of the type Float.
-- In addition, the following operators are predefined for -- the root numeric types:
function "*" (Left : root_integer; Right : root_real)
return root_real;
function "*" (Left : root_real; Right : root_integer)
return root_real;
function "/" (Left : root_real; Right : root_integer)
return root_real;
-- The type universal_fixed is predefined. -- The only multiplying operators defined between -- fixed point types are
function "*" (Left : universal_fixed; Right : universal_fixed)
return universal_fixed;
function "/" (Left : universal_fixed; Right : universal_fixed)
return universal_fixed;
-- The declaration of type Character is based on the standard
-- ISO 8859-1 character set.
-- There are no character literals corresponding to the -- positions for control characters. They are indicated in -- italics in this definition (see 3.5.2). type Character is (nul, soh, stx, etx, eot, enq, ack, bel, bs, ht, lf, vt, ff, cr, so, si, dle, dc1, dc2, dc3, dc4, nak, syn, etb, can, em, sub, esc, fs, gs, rs, us, ' ', '!', '"', '#', '$', '%', '&', ''', '(', ')', '*', '+', ',', '-', '.', '/', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', ':', ';', '<', '=', '>', '?', '´, 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', '[', '\', ']', '^', '_', '`', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', '{', '|', '}', '~', del, reserved_128, reserved_129, bph, nbh, reserved_132, nel, ssa, esa, hts, htj, vts, pld, plu, ri, ss2, ss3, dcs, pu1, pu2, sts, cch, mw, spa, epa, sos, reserved_153, sci, csi, st, osc, pm, apc, ... );
-- The predefined operators for the type Character are the -- same as for any enumeration type. -- The declaration of type Wide_Character is based on the -- standard ISO 10646 BMP character set. The first 256 positions -- have the same contents as type Character (see 3.5.2). type Wide_Character is (nul, soh ... FFFE, FFFF); package ASCII is ... end ASCII; --Obsolescent; (see J.5). -- Predefined string types:
type String is array(Positive range <>) of Character; pragma Pack(String);
-- The predefined operators for this type are as follows:
-- function "=" (Left, Right: String) return Boolean; -- function "/=" (Left, Right: String) return Boolean; -- function "<" (Left, Right: String) return Boolean; -- function "<=" (Left, Right: String) return Boolean; -- function ">" (Left, Right: String) return Boolean; -- function ">=" (Left, Right: String) return Boolean;
-- function "&" (Left: String; Right: String) -- return String; -- function "&" (Left: Character; Right: String) -- return String; -- function "&" (Left: String; Right: Character) -- return String; -- function "&" (Left: Character; Right: Character) -- return String;
type Wide_String is array(Positive range <>) of Wide_Character; pragma Pack(Wide_String);
-- The predefined operators for this type correspond to those -- for String
type Duration is delta
implementation-defined range implementation-defined;
-- The predefined operators for the type Duration are the -- same as for any fixed point type.
-- The predefined exceptions:
Constraint_Error: exception; Program_Error : exception; Storage_Error : exception; Tasking_Error : exception;
end Standard;
NOTES
package Ada is
pragma Pure(Ada);
end Ada;
package Ada.Characters is pragma Pure(Characters); end Ada.Characters;
package Ada.Characters.Handling is pragma Preelaborate(Handling);
-- Character classification functions
function Is_Control (Item : in Character) return Boolean;
function Is_Graphic (Item : in Character) return Boolean;
function Is_Letter (Item : in Character) return Boolean;
function Is_Lower (Item : in Character) return Boolean;
function Is_Upper (Item : in Character) return Boolean;
function Is_Basic (Item : in Character) return Boolean;
function Is_Digit (Item : in Character) return Boolean;
function Is_Decimal_Digit (Item : in Character) return Boolean
renames Is_Digit;
function Is_Hexadecimal_Digit (Item : in Character) return Boolean;
function Is_Alphanumeric (Item : in Character) return Boolean;
function Is_Special (Item : in Character) return Boolean;
-- Conversion functions for Character and String
function To_Lower (Item : in Character) return Character; function To_Upper (Item : in Character) return Character; function To_Basic (Item : in Character) return Character;
function To_Lower (Item : in String) return String; function To_Upper (Item : in String) return String; function To_Basic (Item : in String) return String;
-- Classifications of and conversions -- between Character and ISO 646
subtype ISO_646 is
Character range Character'Val(0) .. Character'Val(127);
function Is_ISO_646 (Item : in Character) return Boolean; function Is_ISO_646 (Item : in String) return Boolean;
function To_ISO_646 (Item : in Character;
Substitute : in ISO_646 := ' ')
return ISO_646;
function To_ISO_646 (Item : in String;
Substitute : in ISO_646 := ' ')
return String;
-- Classifications of and conversions -- between Wide_Character and Character.
function Is_Character (Item : in Wide_Character) return Boolean; function Is_String (Item : in Wide_String) return Boolean;
function To_Character (Item : in Wide_Character;
Substitute : in Character := ' ')
return Character;
function To_String (Item : in Wide_String;
Substitute : in Character := ' ')
return String;
function To_Wide_Character (Item : in Character)
return Wide_Character;
function To_Wide_String (Item : in String) return Wide_String;
end Ada.Characters.Handling;
True if Item is a control character. A control character is a character whose position is in one of the ranges 0..31 or 127..159.
True if Item is a graphic character. A graphic character is a character whose position is in one of the ranges 32..126 or 160..255.
True if Item is a letter. A letter is a character that is in one of the ranges 'A'..'Z' or 'a'..'z', or whose position is in one of the ranges 192..214, 216..246, or 248..255.
True if Item is a lower-case letter. A lower-case letter is a character that is in the range 'a'..'z', or whose position is in one of the ranges 223..246 or 248..255.
True if Item is an upper-case letter. An upper-case letter is a character that is in the range 'A'..'Z' or whose position is in one of the ranges 192..214 or 216.. 222.
True if Item is a basic letter. A basic letter is a character that is in one of the ranges 'A'..'Z' and 'a'..'z', or that is one of the following: an upper- or lower-case AE diphthong, an upper- or lower-case Icelandic eth, an upper- or lower-case Icelandic thorn, or a sharp-s.
True if Item is a decimal digit. A decimal digit is a character in the range '0'..'9'.
A renaming of Is_Digit.
True if Item is a hexadecimal digit. A hexadecimal digit is a character that is either a decimal digit or that is in one of the ranges 'A' .. 'F' or 'a' .. 'f'.
True if Item is an alphanumeric character. An alphanumeric character is a character that is either a letter or a decimal digit.
True if Item is a special graphic character. A special graphic character is a graphic character that is not alphanumeric.
Returns the corresponding lower-case value for Item if Is_Upper(Item), and returns Item otherwise.
Returns the corresponding upper-case value for Item if Is_Lower(Item) and Item has an upper-case form, and returns Item otherwise. The lower case letters sharp-s and y-diaeresis do not have upper case forms.
Returns the letter corresponding to Item but with no diacritical mark, if Item is a letter but not a basic letter; returns Item otherwise.
The function whose formal parameter, Item, is of type Character returns True if Item is in the subtype ISO_646.
The function whose formal parameter, Item, is of type String returns True if Is_ISO_646(Item(I)) is True for each I in Item'Range.
The function whose first formal parameter, Item, is of type Character returns Item if Is_ISO_646(Item), and returns the Substitute ISO_646 character otherwise.
The function whose first formal parameter, Item, is of type String returns the String whose Range is 1..Item'Length and each of whose elements is given by To_ISO_646 of the corresponding element in Item.
Returns True if Wide_Character'Pos(Item) <= Character'Pos(Character'Last).
Returns True if Is_Character(Item(I)) is True for each I in Item'Range.
Returns the Character corresponding to Item if Is_Character(Item), and returns the Substitute Character otherwise.
Returns the String whose range is 1..Item'Length and each of whose elements is given by To_Character of the corresponding element in Item.
Returns the Wide_Character X such that Character'Pos(Item) = Wide_Character'Pos(X).
Returns the Wide_String whose range is 1..Item'Length and each of whose elements is given by To_Wide_Character of the corresponding element in Item.
NOTES
package Ada.Characters.Latin_1 is
pragma Pure(Latin_1);
-- Control characters:
NUL : constant Character := Character'Val(0); SOH : constant Character := Character'Val(1); STX : constant Character := Character'Val(2); ETX : constant Character := Character'Val(3); EOT : constant Character := Character'Val(4); ENQ : constant Character := Character'Val(5); ACK : constant Character := Character'Val(6); BEL : constant Character := Character'Val(7); BS : constant Character := Character'Val(8); HT : constant Character := Character'Val(9); LF : constant Character := Character'Val(10); VT : constant Character := Character'Val(11); FF : constant Character := Character'Val(12); CR : constant Character := Character'Val(13); SO : constant Character := Character'Val(14); SI : constant Character := Character'Val(15);
DLE : constant Character := Character'Val(16); DC1 : constant Character := Character'Val(17); DC2 : constant Character := Character'Val(18); DC3 : constant Character := Character'Val(19); DC4 : constant Character := Character'Val(20); NAK : constant Character := Character'Val(21); SYN : constant Character := Character'Val(22); ETB : constant Character := Character'Val(23); CAN : constant Character := Character'Val(24); EM : constant Character := Character'Val(25); SUB : constant Character := Character'Val(26); ESC : constant Character := Character'Val(27); FS : constant Character := Character'Val(28); GS : constant Character := Character'Val(29); RS : constant Character := Character'Val(30); US : constant Character := Character'Val(31);
-- ISO 646 graphic characters:
Space : constant Character := ' ';
-- Character'Val(32)
Exclamation : constant Character := '!';
-- Character'Val(33)
Quotation : constant Character := '"';
-- Character'Val(34)
Number_Sign : constant Character := '#';
-- Character'Val(35)
Dollar_Sign : constant Character := '$';
-- Character'Val(36)
Percent_Sign : constant Character := '%';
-- Character'Val(37)
Ampersand : constant Character := '&';
-- Character'Val(38)
Apostrophe : constant Character := ''';
-- Character'Val(39)
Left_Parenthesis : constant Character := '(';
-- Character'Val(40)
Right_Parenthesis : constant Character := ')';
-- Character'Val(41)
Asterisk : constant Character := '*';
-- Character'Val(42)
Plus_Sign : constant Character := '+';
-- Character'Val(43)
Comma : constant Character := ',';
-- Character'Val(44)
Hyphen : constant Character := '-';
-- Character'Val(45)
Minus_Sign : Character renames Hyphen;
Full_Stop : constant Character := '.';
-- Character'Val(46)
Solidus : constant Character := '/';
-- Character'Val(47)
-- Decimal digits '0' though '9' are at positions 48 through 57
Colon : constant Character := ':';
-- Character'Val(58)
Semicolon : constant Character := ';';
-- Character'Val(59)
Less_Than_Sign : constant Character := '<';
-- Character'Val(60)
Equals_Sign : constant Character := '=';
-- Character'Val(61)
Greater_Than_Sign : constant Character := '>';
-- Character'Val(62)
Question : constant Character := '?';
-- Character'Val(63)
Commercial_At : constant Character := '´;
-- Character'Val(64)
-- Letters 'A' through 'Z' are at positions 65 through 90
Left_Square_Bracket : constant Character := '[';
-- Character'Val(91)
Reverse_Solidus : constant Character := '\';
-- Character'Val(92)
Right_Square_Bracket : constant Character := ']';
-- Character'Val(93)
Circumflex : constant Character := '^';
-- Character'Val(94)
Low_Line : constant Character := '_';
-- Character'Val(95)
Grave : constant Character := '`';
-- Character'Val(96)
LC_A : constant Character := 'a';
-- Character'Val(97)
LC_B : constant Character := 'b';
-- Character'Val(98)
LC_C : constant Character := 'c';
-- Character'Val(99)
LC_D : constant Character := 'd';
-- Character'Val(100)
LC_E : constant Character := 'e';
-- Character'Val(101)
LC_F : constant Character := 'f';
-- Character'Val(102)
LC_G : constant Character := 'g';
-- Character'Val(103)
LC_H : constant Character := 'h';
-- Character'Val(104)
LC_I : constant Character := 'i';
-- Character'Val(105)
LC_J : constant Character := 'j';
-- Character'Val(106)
LC_K : constant Character := 'k';
-- Character'Val(107)
LC_L : constant Character := 'l';
-- Character'Val(108)
LC_M : constant Character := 'm';
-- Character'Val(109)
LC_N : constant Character := 'n';
-- Character'Val(110)
LC_O : constant Character := 'o';
-- Character'Val(111)
LC_P : constant Character := 'p';
-- Character'Val(112)
LC_Q : constant Character := 'q';
-- Character'Val(113)
LC_R : constant Character := 'r';
-- Character'Val(114)
LC_S : constant Character := 's';
-- Character'Val(115)
LC_T : constant Character := 't';
-- Character'Val(116)
LC_U : constant Character := 'u';
-- Character'Val(117)
LC_V : constant Character := 'v';
-- Character'Val(118)
LC_W : constant Character := 'w';
-- Character'Val(119)
LC_X : constant Character := 'x';
-- Character'Val(120)
LC_Y : constant Character := 'y';
-- Character'Val(121)
LC_Z : constant Character := 'z';
-- Character'Val(122)
Left_Curly_Bracket : constant Character := '{';
-- Character'Val(123)
Vertical_Line : constant Character := '|';
-- Character'Val(124)
Right_Curly_Bracket : constant Character := '}';
-- Character'Val(125)
Tilde : constant Character := '~';
-- Character'Val(126)
DEL : constant Character := Character'Val(127);
-- ISO 6429 control characters:
IS4 : Character renames FS; IS3 : Character renames GS; IS2 : Character renames RS; IS1 : Character renames US;
Reserved_128 : constant Character := Character'Val(128); Reserved_129 : constant Character := Character'Val(129); BPH : constant Character := Character'Val(130); NBH : constant Character := Character'Val(131); Reserved_132 : constant Character := Character'Val(132); NEL : constant Character := Character'Val(133); SSA : constant Character := Character'Val(134); ESA : constant Character := Character'Val(135); HTS : constant Character := Character'Val(136); HTJ : constant Character := Character'Val(137); VTS : constant Character := Character'Val(138); PLD : constant Character := Character'Val(139); PLU : constant Character := Character'Val(140); RI : constant Character := Character'Val(141); SS2 : constant Character := Character'Val(142); SS3 : constant Character := Character'Val(143);
DCS : constant Character := Character'Val(144); PU1 : constant Character := Character'Val(145); PU2 : constant Character := Character'Val(146); STS : constant Character := Character'Val(147); CCH : constant Character := Character'Val(148); MW : constant Character := Character'Val(149); SPA : constant Character := Character'Val(150); EPA : constant Character := Character'Val(151);
SOS : constant Character := Character'Val(152); Reserved_153 : constant Character := Character'Val(153); SCI : constant Character := Character'Val(154); CSI : constant Character := Character'Val(155); ST : constant Character := Character'Val(156); OSC : constant Character := Character'Val(157); PM : constant Character := Character'Val(158); APC : constant Character := Character'Val(159);
-- Other graphic characters:
-- Character positions 160 (16#A0#) .. 175 (16#AF#):
No_Break_Space : constant Character := ' ';
-- Character'Val(160)
NBSP : Character renames No_Break_Space;
Inverted_Exclamation : constant Character :=
Character'Val(161);
Cent_Sign : constant Character :=
Character'Val(162);
Pound_Sign : constant Character :=
Character'Val(163);
Currency_Sign : constant Character :=
Character'Val(164);
Yen_Sign : constant Character :=
Character'Val(165);
Broken_Bar : constant Character :=
Character'Val(166);
Section_Sign : constant Character :=
Character'Val(167);
Diaeresis : constant Character :=
Character'Val(168);
Copyright_Sign : constant Character :=
Character'Val(169);
Feminine_Ordinal_Indicator : constant Character :=
Character'Val(170);
Left_Angle_Quotation : constant Character :=
Character'Val(171);
Not_Sign : constant Character :=
Character'Val(172);
Soft_Hyphen : constant Character :=
Character'Val(173);
Registered_Trade_Mark_Sign : constant Character :=
Character'Val(174);
Macron : constant Character :=
Character'Val(175);
-- Character positions 176 (16#B0#) .. 191 (16#BF#):
Degree_Sign : constant Character :=
Character'Val(176);
Ring_Above : Character renames Degree_Sign;
Plus_Minus_Sign : constant Character :=
Character'Val(177);
Superscript_Two : constant Character :=
Character'Val(178);
Superscript_Three : constant Character :=
Character'Val(179);
Acute : constant Character :=
Character'Val(180);
Micro_Sign : constant Character :=
Character'Val(181);
Pilcrow_Sign : constant Character :=
Character'Val(182);
Paragraph_Sign : Character renames Pilcrow_Sign;
Middle_Dot : constant Character :=
Character'Val(183);
Cedilla : constant Character :=
Character'Val(184);
Superscript_One : constant Character :=
Character'Val(185);
Masculine_Ordinal_Indicator : constant Character :=
Character'Val(186);
Right_Angle_Quotation : constant Character :=
Character'Val(187);
Fraction_One_Quarter : constant Character :=
Character'Val(188);
Fraction_One_Half : constant Character :=
Character'Val(189);
Fraction_Three_Quarters : constant Character :=
Character'Val(190);
Inverted_Question : constant Character :=
Character'Val(191);
-- Character positions 192 (16#C0#) .. 207 (16#CF#):
UC_A_Grave : constant Character :=
Character'Val(192);
UC_A_Acute : constant Character :=
Character'Val(193);
UC_A_Circumflex : constant Character :=
Character'Val(194);
UC_A_Tilde : constant Character :=
Character'Val(195);
UC_A_Diaeresis : constant Character :=
Character'Val(196);
UC_A_Ring : constant Character :=
Character'Val(197);
UC_AE_Diphthong : constant Character :=
Character'Val(198);
UC_C_Cedilla : constant Character :=
Character'Val(199);
UC_E_Grave : constant Character :=
Character'Val(200);
UC_E_Acute : constant Character :=
Character'Val(201);
UC_E_Circumflex : constant Character :=
Character'Val(202);
UC_E_Diaeresis : constant Character :=
Character'Val(203);
UC_I_Grave : constant Character :=
Character'Val(204);
UC_I_Acute : constant Character :=
Character'Val(205);
UC_I_Circumflex : constant Character :=
Character'Val(206);
UC_I_Diaeresis : constant Character :=
Character'Val(207);
-- Character positions 208 (16#D0#) .. 223 (16#DF#):
UC_Icelandic_Eth : constant Character :=
Character'Val(208);
UC_N_Tilde : constant Character :=
Character'Val(209);
UC_O_Grave : constant Character :=
Character'Val(210);
UC_O_Acute : constant Character :=
Character'Val(211);
UC_O_Circumflex : constant Character :=
Character'Val(212);
UC_O_Tilde : constant Character :=
Character'Val(213);
UC_O_Diaeresis : constant Character :=
Character'Val(214);
Multiplication_Sign : constant Character :=
Character'Val(215);
UC_O_Oblique_Stroke : constant Character :=
Character'Val(216);
UC_U_Grave : constant Character :=
Character'Val(217);
UC_U_Acute : constant Character :=
Character'Val(218);
UC_U_Circumflex : constant Character :=
Character'Val(219);
UC_U_Diaeresis : constant Character :=
Character'Val(220);
UC_Y_Acute : constant Character :=
Character'Val(221);
UC_Icelandic_Thorn : constant Character :=
Character'Val(222);
LC_German_Sharp_S : constant Character :=
Character'Val(223);
-- Character positions 224 (16#E0#) .. 239 (16#EF#):
LC_A_Grave : constant Character :=
Character'Val(224);
LC_A_Acute : constant Character :=
Character'Val(225);
LC_A_Circumflex : constant Character :=
Character'Val(226);
LC_A_Tilde : constant Character :=
Character'Val(227);
LC_A_Diaeresis : constant Character :=
Character'Val(228);
LC_A_Ring : constant Character :=
Character'Val(229);
LC_AE_Diphthong : constant Character :=
Character'Val(230);
LC_C_Cedilla : constant Character :=
Character'Val(231);
LC_E_Grave : constant Character :=
Character'Val(232);
LC_E_Acute : constant Character :=
Character'Val(233);
LC_E_Circumflex : constant Character :=
Character'Val(234);
LC_E_Diaeresis : constant Character :=
Character'Val(235);
LC_I_Grave : constant Character :=
Character'Val(236);
LC_I_Acute : constant Character :=
Character'Val(237);
LC_I_Circumflex : constant Character :=
Character'Val(238);
LC_I_Diaeresis : constant Character :=
Character'Val(239);
-- Character positions 240 (16#F0#) .. 255 (16#FF#):
LC_Icelandic_Eth : constant Character :=
Character'Val(240);
LC_N_Tilde : constant Character :=
Character'Val(241);
LC_O_Grave : constant Character :=
Character'Val(242);
LC_O_Acute : constant Character :=
Character'Val(243);
LC_O_Circumflex : constant Character :=
Character'Val(244);
LC_O_Tilde : constant Character :=
Character'Val(245);
LC_O_Diaeresis : constant Character :=
Character'Val(246);
Division_Sign : constant Character :=
Character'Val(247);
LC_O_Oblique_Stroke : constant Character :=
Character'Val(248);
LC_U_Grave : constant Character :=
Character'Val(249);
LC_U_Acute : constant Character :=
Character'Val(250);
LC_U_Circumflex : constant Character :=
Character'Val(251);
LC_U_Diaeresis : constant Character :=
Character'Val(252);
LC_Y_Acute : constant Character :=
Character'Val(253);
LC_Icelandic_Thorn : constant Character :=
Character'Val(254);
LC_Y_Diaeresis : constant Character :=
Character'Val(255);
end Ada.Characters.Latin_1;
package Ada.Strings is pragma Pure(Strings);
Space : constant Character := ' '; Wide_Space : constant Wide_Character := ' ';
Length_Error, Pattern_Error, Index_Error, Translation_Error
: exception;
type Alignment is (Left, Right, Center); type Truncation is (Left, Right, Error); type Membership is (Inside, Outside); type Direction is (Forward, Backward); type Trim_End is (Left, Right, Both); end Ada.Strings;
package Ada.Strings.Maps is pragma Preelaborate(Maps);
-- Representation for a set of character values: type Character_Set is private;
Null_Set : constant Character_Set;
type Character_Range is
record
Low : Character;
High : Character;
end record;
-- Represents Character range Low..High
type Character_Ranges is
array (Positive range <>) of Character_Range;
function To_Set (Ranges : in Character_Ranges)
return Character_Set;
function To_Set (Span : in Character_Range)
return Character_Set;
function To_Ranges (Set : in Character_Set)
return Character_Ranges;
function "=" (Left, Right : in Character_Set) return Boolean;
function "not" (Right : in Character_Set)
return Character_Set;
function "and" (Left, Right : in Character_Set)
return Character_Set;
function "or" (Left, Right : in Character_Set)
return Character_Set;
function "xor" (Left, Right : in Character_Set)
return Character_Set;
function "-" (Left, Right : in Character_Set)
return Character_Set;
function Is_In (Element : in Character;
Set : in Character_Set)
return Boolean;
function Is_Subset (Elements : in Character_Set;
Set : in Character_Set)
return Boolean;
function "<=" (Left : in Character_Set;
Right : in Character_Set)
return Boolean renames Is_Subset;
-- Alternative representation for a set of character values: subtype Character_Sequence is String;
function To_Set (Sequence : in Character_Sequence)
return Character_Set;
function To_Set (Singleton : in Character) return Character_Set;
function To_Sequence (Set : in Character_Set)
return Character_Sequence;
-- Representation for a character to character mapping: type Character_Mapping is private;
function Value (Map : in Character_Mapping;
Element : in Character)
return Character;
Identity : constant Character_Mapping;
function To_Mapping (From, To : in Character_Sequence)
return Character_Mapping;
function To_Domain (Map : in Character_Mapping)
return Character_Sequence;
function To_Range (Map : in Character_Mapping)
return Character_Sequence;
type Character_Mapping_Function is
access function (From : in Character) return Character;
private ... -- not specified by the language end Ada.Strings.Maps;
function To_Set (Ranges : in Character_Ranges) return Character_Set;
function To_Set (Span : in Character_Range) return Character_Set;
function To_Ranges (Set : in Character_Set) return Character_Ranges;
function "=" (Left, Right : in Character_Set) return Boolean;
function Is_In (Element : in Character;
Set : in Character_Set);
return Boolean;
function Is_Subset (Elements : in Character_Set;
Set : in Character_Set)
return Boolean;
subtype Character_Sequence is String;
function To_Set (Sequence : in Character_Sequence) return Character_Set; function To_Set (Singleton : in Character) return Character_Set;
function To_Sequence (Set : in Character_Set) return Character_Sequence;
type Character_Mapping is private;
function Value (Map : in Character_Mapping;
Element : in Character)
return Character;
Identity : constant Character_Mapping;
function To_Mapping (From, To : in Character_Sequence) return Character_Mapping;
function To_Domain (Map : in Character_Mapping) return Character_Sequence;
function To_Range (Map : in Character_Mapping) return Character_Sequence;
NOTES
with Ada.Strings.Maps; package Ada.Strings.Fixed is pragma Preelaborate(Fixed);
-- "Copy" procedure for strings of possibly different lengths
procedure Move (Source : in String;
Target : out String;
Drop : in Truncation := Error;
Justify : in Alignment := Left;
Pad : in Character := Space);
-- Search subprograms
function Index (Source : in String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward)
return Natural;
function Index_Non_Blank (Source : in String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in String;
Mapping : in Maps.Character_Mapping)
return String;
procedure Translate (Source : in out String;
Mapping : in Maps.Character_Mapping);
function Translate (Source : in String;
Mapping : in Maps.Character_Mapping_Function)
return String;
procedure Translate
(Source : in out String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in String;
Low : in Positive;
High : in Natural;
By : in String)
return String;
procedure Replace_Slice (Source : in out String;
Low : in Positive;
High : in Natural;
By : in String;
Drop : in Truncation := Error;
Justify : in Alignment := Left;
Pad : in Character := Space);
function Insert (Source : in String;
Before : in Positive;
New_Item : in String)
return String;
procedure Insert (Source : in out String;
Before : in Positive;
New_Item : in String;
Drop : in Truncation := Error);
function Overwrite (Source : in String;
Position : in Positive;
New_Item : in String)
return String;
procedure Overwrite (Source : in out String;
Position : in Positive;
New_Item : in String;
Drop : in Truncation := Right);
function Delete (Source : in String;
From : in Positive;
Through : in Natural)
return String;
procedure Delete (Source : in out String;
From : in Positive;
Through : in Natural;
Justify : in Alignment := Left;
Pad : in Character := Space);
-- String selector subprograms
function Trim (Source : in String;
Side : in Trim_End)
return String;
procedure Trim (Source : in out String;
Side : in Trim_End;
Justify : in Alignment := Left;
Pad : in Character := Space);
function Trim (Source : in String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return String;
procedure Trim (Source : in out String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set;
Justify : in Alignment := Strings.Left;
Pad : in Character := Space);
function Head (Source : in String;
Count : in Natural;
Pad : in Character := Space)
return String;
procedure Head (Source : in out String;
Count : in Natural;
Justify : in Alignment := Left;
Pad : in Character := Space);
function Tail (Source : in String;
Count : in Natural;
Pad : in Character := Space)
return String;
procedure Tail (Source : in out String;
Count : in Natural;
Justify : in Alignment := Left;
Pad : in Character := Space);
--String constructor functions
function "*" (Left : in Natural;
Right : in Character) return String;
function "*" (Left : in Natural;
Right : in String) return String;
end Ada.Strings.Fixed;
procedure Move (Source : in String;
Target : out String;
Drop : in Truncation := Error;
Justify : in Alignment := Left;
Pad : in Character := Space);
function Index (Source : in String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward)
return Natural;
function Index_Non_Blank (Source : in String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
function Translate (Source : in String;
Mapping : in Maps.Character_Mapping)
return String;
function Translate (Source : in String;
Mapping : in Maps.Character_Mapping_Function)
return String;
procedure Translate (Source : in out String;
Mapping : in Maps.Character_Mapping);
procedure Translate (Source : in out String;
Mapping : in Maps.Character_Mapping_Function);
function Replace_Slice (Source : in String;
Low : in Positive;
High : in Natural;
By : in String)
return String;
procedure Replace_Slice (Source : in out String;
Low : in Positive;
High : in Natural;
By : in String;
Drop : in Truncation := Error;
Justify : in Alignment := Left;
Pad : in Character := Space);
function Insert (Source : in String;
Before : in Positive;
New_Item : in String)
return String;
procedure Insert (Source : in out String;
Before : in Positive;
New_Item : in String;
Drop : in Truncation := Error);
function Overwrite (Source : in String;
Position : in Positive;
New_Item : in String)
return String;
procedure Overwrite (Source : in out String;
Position : in Positive;
New_Item : in String;
Drop : in Truncation := Right);
function Delete (Source : in String;
From : in Positive;
Through : in Natural)
return String;
procedure Delete (Source : in out String;
From : in Positive;
Through : in Natural;
Justify : in Alignment := Left;
Pad : in Character := Space);
function Trim (Source : in String;
Side : in Trim_End)
return String;
procedure Trim (Source : in out String;
Side : in Trim_End;
Justify : in Alignment := Left;
Pad : in Character := Space);
function Trim (Source : in String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return String;
procedure Trim (Source : in out String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set;
Justify : in Alignment := Strings.Left;
Pad : in Character := Space);
function Head (Source : in String;
Count : in Natural;
Pad : in Character := Space)
return String;
procedure Head (Source : in out String;
Count : in Natural;
Justify : in Alignment := Left;
Pad : in Character := Space);
function Tail (Source : in String;
Count : in Natural;
Pad : in Character := Space)
return String;
procedure Tail (Source : in out String;
Count : in Natural;
Justify : in Alignment := Left;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character) return String;
function "*" (Left : in Natural;
Right : in String) return String;
NOTES
with Ada.Strings.Maps; package Ada.Strings.Bounded is pragma Preelaborate(Bounded);
generic
Max : Positive; -- Maximum length of a Bounded_String
package Generic_Bounded_Length is
Max_Length : constant Positive := Max;
type Bounded_String is private;
Null_Bounded_String : constant Bounded_String;
subtype Length_Range is Natural range 0 .. Max_Length;
function Length (Source : in Bounded_String)
return Length_Range;
-- Conversion, Concatenation, and Selection functions
function To_Bounded_String (Source : in String;
Drop : in Truncation := Error)
return Bounded_String;
function To_String (Source : in Bounded_String) return String;
function Append (Left, Right : in Bounded_String;
Drop : in Truncation := Error)
return Bounded_String;
function Append (Left : in Bounded_String;
Right : in String;
Drop : in Truncation := Error)
return Bounded_String;
function Append (Left : in String;
Right : in Bounded_String;
Drop : in Truncation := Error)
return Bounded_String;
function Append (Left : in Bounded_String;
Right : in Character;
Drop : in Truncation := Error)
return Bounded_String;
function Append (Left : in Character;
Right : in Bounded_String;
Drop : in Truncation := Error)
return Bounded_String;
procedure Append (Source : in out Bounded_String;
New_Item : in Bounded_String;
Drop : in Truncation := Error);
procedure Append (Source : in out Bounded_String;
New_Item : in String;
Drop : in Truncation := Error);
procedure Append (Source : in out Bounded_String;
New_Item : in Character;
Drop : in Truncation := Error);
function "&" (Left, Right : in Bounded_String)
return Bounded_String;
function "&" (Left : in Bounded_String; Right : in String)
return Bounded_String;
function "&" (Left : in String; Right : in Bounded_String)
return Bounded_String;
function "&" (Left : in Bounded_String; Right : in Character)
return Bounded_String;
function "&" (Left : in Character; Right : in Bounded_String)
return Bounded_String;
function Element (Source : in Bounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Bounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Bounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Bounded_String) return Boolean;
function "=" (Left : in Bounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Bounded_String)
return Boolean;
function "<" (Left, Right : in Bounded_String) return Boolean;
function "<" (Left : in Bounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Bounded_String)
return Boolean;
function "<=" (Left, Right : in Bounded_String) return Boolean;
function "<=" (Left : in Bounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Bounded_String)
return Boolean;
function ">" (Left, Right : in Bounded_String) return Boolean;
function ">" (Left : in Bounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Bounded_String)
return Boolean;
function ">=" (Left, Right : in Bounded_String) return Boolean;
function ">=" (Left : in Bounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Bounded_String)
return Boolean;
-- Search functions
function Index (Source : in Bounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Bounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Bounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward)
return Natural;
function Index_Non_Blank (Source : in Bounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Bounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Bounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Bounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Bounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Bounded_String;
Mapping : in Maps.Character_Mapping)
return Bounded_String;
procedure Translate (Source : in out Bounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Bounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Bounded_String;
procedure Translate
(Source : in out Bounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Bounded_String;
Low : in Positive;
High : in Natural;
By : in String;
Drop : in Truncation := Error)
return Bounded_String;
procedure Replace_Slice (Source : in out Bounded_String;
Low : in Positive;
High : in Natural;
By : in String;
Drop : in Truncation := Error);
function Insert (Source : in Bounded_String;
Before : in Positive;
New_Item : in String;
Drop : in Truncation := Error)
return Bounded_String;
procedure Insert (Source : in out Bounded_String;
Before : in Positive;
New_Item : in String;
Drop : in Truncation := Error);
function Overwrite (Source : in Bounded_String;
Position : in Positive;
New_Item : in String;
Drop : in Truncation := Error)
return Bounded_String;
procedure Overwrite (Source : in out Bounded_String;
Position : in Positive;
New_Item : in String;
Drop : in Truncation := Error);
function Delete (Source : in Bounded_String;
From : in Positive;
Through : in Natural)
return Bounded_String;
procedure Delete (Source : in out Bounded_String;
From : in Positive;
Through : in Natural);
-- String selector subprograms
function Trim (Source : in Bounded_String;
Side : in Trim_End)
return Bounded_String;
procedure Trim (Source : in out Bounded_String;
Side : in Trim_End);
function Trim (Source : in Bounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Bounded_String;
procedure Trim (Source : in out Bounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Bounded_String;
Count : in Natural;
Pad : in Character := Space;
Drop : in Truncation := Error)
return Bounded_String;
procedure Head (Source : in out Bounded_String;
Count : in Natural;
Pad : in Character := Space;
Drop : in Truncation := Error);
function Tail (Source : in Bounded_String;
Count : in Natural;
Pad : in Character := Space;
Drop : in Truncation := Error)
return Bounded_String;
procedure Tail (Source : in out Bounded_String;
Count : in Natural;
Pad : in Character := Space;
Drop : in Truncation := Error);
-- String constructor subprograms
function "*" (Left : in Natural;
Right : in Character)
return Bounded_String;
function "*" (Left : in Natural;
Right : in String)
return Bounded_String;
function "*" (Left : in Natural;
Right : in Bounded_String)
return Bounded_String;
function Replicate (Count : in Natural;
Item : in Character;
Drop : in Truncation := Error)
return Bounded_String;
function Replicate (Count : in Natural;
Item : in String;
Drop : in Truncation := Error)
return Bounded_String;
function Replicate (Count : in Natural;
Item : in Bounded_String;
Drop : in Truncation := Error)
return Bounded_String;
private
... -- not specified by the language
end Generic_Bounded_Length;
end Ada.Strings.Bounded;
function Length (Source : in Bounded_String) return Length_Range;
function To_Bounded_String (Source : in String;
Drop : in Truncation := Error)
return Bounded_String;
function To_String (Source : in Bounded_String) return String;
function Element (Source : in Bounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Bounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Bounded_String;
Low : in Positive;
High : in Natural)
return String;
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<=" (Left, Right : in Unbounded_String) return Boolean;
function "<=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "<=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">" (Left, Right : in Unbounded_String) return Boolean;
function ">" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">" (Left : in String; Right : in Unbounded_String)
return Boolean;
function ">=" (Left, Right : in Unbounded_String) return Boolean;
function ">=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function ">=" (Left : in String; Right : in Unbounded_String)
return Boolean;
-- Search subprograms
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Index (Source : in Unbounded_String;
Pattern : in String;
Going : in Direction := Forward;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Index (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership := Inside;
Going : in Direction := Forward) return Natural;
function Index_Non_Blank (Source : in Unbounded_String;
Going : in Direction := Forward)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping
:= Maps.Identity)
return Natural;
function Count (Source : in Unbounded_String;
Pattern : in String;
Mapping : in Maps.Character_Mapping_Function)
return Natural;
function Count (Source : in Unbounded_String;
Set : in Maps.Character_Set)
return Natural;
procedure Find_Token (Source : in Unbounded_String;
Set : in Maps.Character_Set;
Test : in Membership;
First : out Positive;
Last : out Natural);
-- String translation subprograms
function Translate (Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping)
return Unbounded_String;
procedure Translate (Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping);
function Translate
(Source : in Unbounded_String;
Mapping : in Maps.Character_Mapping_Function)
return Unbounded_String;
procedure Translate
(Source : in out Unbounded_String;
Mapping : in Maps.Character_Mapping_Function);
-- String transformation subprograms
function Replace_Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String)
return Unbounded_String;
procedure Replace_Slice (Source : in out Unbounded_String;
Low : in Positive;
High : in Natural;
By : in String);
function Insert (Source : in Unbounded_String;
Before : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Insert (Source : in out Unbounded_String;
Before : in Positive;
New_Item : in String);
function Overwrite (Source : in Unbounded_String;
Position : in Positive;
New_Item : in String)
return Unbounded_String;
procedure Overwrite (Source : in out Unbounded_String;
Position : in Positive;
New_Item : in String);
function Delete (Source : in Unbounded_String;
From : in Positive;
Through : in Natural)
return Unbounded_String;
procedure Delete (Source : in out Unbounded_String;
From : in Positive;
Through : in Natural);
function Trim (Source : in Unbounded_String;
Side : in Trim_End)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Side : in Trim_End);
function Trim (Source : in Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set)
return Unbounded_String;
procedure Trim (Source : in out Unbounded_String;
Left : in Maps.Character_Set;
Right : in Maps.Character_Set);
function Head (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Head (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function Tail (Source : in Unbounded_String;
Count : in Natural;
Pad : in Character := Space)
return Unbounded_String;
procedure Tail (Source : in out Unbounded_String;
Count : in Natural;
Pad : in Character := Space);
function "*" (Left : in Natural;
Right : in Character)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in String)
return Unbounded_String;
function "*" (Left : in Natural;
Right : in Unbounded_String)
return Unbounded_String;
private ... -- not specified by the language end Ada.Strings.Unbounded;
package Ada.Strings.Maps.Constants is pragma Preelaborate(Constants);
Control_Set : constant Character_Set; Graphic_Set : constant Character_Set; Letter_Set : constant Character_Set; Lower_Set : constant Character_Set; Upper_Set : constant Character_Set; Basic_Set : constant Character_Set; Decimal_Digit_Set : constant Character_Set; Hexadecimal_Digit_Set : constant Character_Set; Alphanumeric_Set : constant Character_Set; Special_Set : constant Character_Set; ISO_646_Set : constant Character_Set;
Lower_Case_Map : constant Character_Mapping;
--Maps to lower case for letters, else identity
Upper_Case_Map : constant Character_Mapping;
--Maps to upper case for letters, else identity
Basic_Map : constant Character_Mapping;
--Maps to basic letter for letters, else identity
private ... -- not specified by the language end Ada.Strings.Maps.Constants;
package Ada.Strings.Wide_Maps is pragma Preelaborate(Wide_Maps);
-- Representation for a set of Wide_Character values: type Wide_Character_Set is private;
Null_Set : constant Wide_Character_Set;
type Wide_Character_Range is
record
Low : Wide_Character;
High : Wide_Character;
end record;
-- Represents Wide_Character range Low..High
type Wide_Character_Ranges is array (Positive range <>)
of Wide_Character_Range;
function To_Set (Ranges : in Wide_Character_Ranges)
return Wide_Character_Set;
function To_Set (Sphrerelevant constructor and selector operations are provided.
Static Semantics
with Ada.Strings.Maps; package Ada.Strings.Unbounded is pragma Preelaborate(Unbounded);
type Unbounded_String is private;
Null_Unbounded_String : constant Unbounded_String;
function Length (Source : in Unbounded_String) return Natural;
type String_Access is access all String; procedure Free (X : in out String_Access);
-- Conversion, Concatenation, and Selection functions
function To_Unbounded_String (Source : in String)
return Unbounded_String;
function To_Unbounded_String (Length : in Natural)
return Unbounded_String;
function To_String (Source : in Unbounded_String) return String;
procedure Append (Source : in out Unbounded_String;
New_Item : in Unbounded_String);
procedure Append (Source : in out Unbounded_String;
New_Item : in String);
procedure Append (Source : in out Unbounded_String;
New_Item : in Character);
function "&" (Left, Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in String)
return Unbounded_String;
function "&" (Left : in String; Right : in Unbounded_String)
return Unbounded_String;
function "&" (Left : in Unbounded_String; Right : in Character)
return Unbounded_String;
function "&" (Left : in Character; Right : in Unbounded_String)
return Unbounded_String;
function Element (Source : in Unbounded_String;
Index : in Positive)
return Character;
procedure Replace_Element (Source : in out Unbounded_String;
Index : in Positive;
By : in Character);
function Slice (Source : in Unbounded_String;
Low : in Positive;
High : in Natural)
return String;
function "=" (Left, Right : in Unbounded_String) return Boolean;
function "=" (Left : in Unbounded_String; Right : in String)
return Boolean;
function "=" (Left : in String; Right : in Unbounded_String)
return Boolean;
function "<" (Left, Right : in Unbounded_String) return Boolean;
function "<" (Left : in Unbounded_String; Right : in String)
return Boolean;