Spec-Zone.ru › Ada 2022
Ada Reference Manual (Ada 2022)

A.10.11 Input-Output for Bounded Strings

The package Text_IO.Bounded_IO provides input-output in human-readable form for Bounded_Strings.

Static Semantics

The generic library package Text_IO.Bounded_IO has the following declaration:
with Ada.Strings.Bounded;
generic
with package Bounded is
new Ada.Strings.Bounded.Generic_Bounded_Length (<>);
package Ada.Text_IO.Bounded_IO
with Global => in out synchronized is
procedure Put
(File : in File_Type;
Item : in Bounded.Bounded_String);
procedure Put
(Item : in Bounded.Bounded_String);
procedure Put_Line
(File : in File_Type;
Item : in Bounded.Bounded_String);
procedure Put_Line
(Item : in Bounded.Bounded_String);
function Get_Line
(File : in File_Type)
return Bounded.Bounded_String;
function Get_Line
return Bounded.Bounded_String;
procedure Get_Line
(File : in File_Type; Item : out Bounded.Bounded_String);
procedure Get_Line
(Item : out Bounded.Bounded_String);
end Ada.Text_IO.Bounded_IO;
For an item of type Bounded_String, the following subprograms are provided:
procedure Put
(File : in File_Type;
Item : in Bounded.Bounded_String);
Equivalent to Text_IO.Put (File, Bounded.To_String(Item));
procedure Put
(Item : in Bounded.Bounded_String);
Equivalent to Text_IO.Put (Bounded.To_String(Item));
procedure Put_Line
(File : in File_Type;
Item : in Bounded.Bounded_String);
Equivalent to Text_IO.Put_Line (File, Bounded.To_String(Item));
procedure Put_Line
(Item : in Bounded.Bounded_String);
Equivalent to Text_IO.Put_Line (Bounded.To_String(Item));
function Get_Line
(File : in File_Type)
return Bounded.Bounded_String;
Returns Bounded.To_Bounded_String(Text_IO.Get_Line(File));
function Get_Line
return Bounded.Bounded_String;
Returns Bounded.To_Bounded_String(Text_IO.Get_Line);
procedure Get_Line
(File : in File_Type; Item : out Bounded.Bounded_String);
Equivalent to Item := Get_Line (File);
procedure Get_Line
(Item : out Bounded.Bounded_String);
Equivalent to Item := Get_Line;


Spec-Zone.ru

Настройки Оффлайн Что нового Помощь О нас
Spec-Zone .ru
спецификации, руководства, описания, API