|
|
DataMuseum.dkPresents historical artifacts from the history of: Rational R1000/400 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Rational R1000/400 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - download
Length: 5120 (0x1400)
Types: Ada Source
Notes: 03_class, FILE, R1k_Segment, e3_tag, package body Complements_A, seg_0488cf
└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000
└─⟦5a81ac88f⟧ »Space Info Vol 1«
└─⟦this⟧
with List, String_Utilities, Unbounded_String;
package body Complements_A is
package Identifier is new Unbounded_String (1);
type Complement is
record
Name : Identifier.Variable_String;
Kind : Kind_Of_Complement;
end record;
package Complements_List is new List (Element => Complement);
A_List : Complements_List.Object;
procedure Create (Name : String; A_Kind : Kind_Of_Complement) is
A_Complement : Complement;
begin
A_Complement.Name := Identifier.Value (Name);
A_Complement.Kind := A_Kind;
if not Exists (Name) then
Complements_List.Insert (A_List, A_Complement);
end if;
end Create;
function Exists (Name : String) return Boolean is
A_Complement : Complement;
begin
Complements_List.Go_First (A_List);
while not Complements_List.At_End (A_List) loop
A_Complement := Complements_List.Get_Current_Element (A_List);
if String_Utilities.Equal
(Name, Identifier.Image (A_Complement.Name)) then
return True;
end if;
Complements_List.Go_Next (A_List);
end loop;
return False;
end Exists;
function Kind_Of (Name : String) return Kind_Of_Complement is
A_Complement : Complement;
begin
if Exists (Name) then
A_Complement := Complements_List.Get_Current_Element (A_List);
return A_Complement.Kind;
end if;
return No_One;
end Kind_Of;
procedure Go_First is
begin
Complements_List.Go_First (A_List);
end Go_First;
procedure Go_Next is
begin
Complements_List.Go_Next (A_List);
end Go_Next;
function At_End return Boolean is
begin
return Complements_List.At_End (A_List);
end At_End;
function Get_Current return String is
A_Complement : Complement;
begin
A_Complement := Complements_List.Get_Current_Element (A_List);
return Identifier.Image (A_Complement.Name);
end Get_Current;
function Get_Current_Kind return Kind_Of_Complement is
A_Complement : Complement;
begin
A_Complement := Complements_List.Get_Current_Element (A_List);
return A_Complement.Kind;
end Get_Current_Kind;
end Complements_A;
nblk1=4
nid=0
hdr6=8
[0x00] rec0=22 rec1=00 rec2=01 rec3=042
[0x01] rec0=00 rec1=00 rec2=04 rec3=004
[0x02] rec0=23 rec1=00 rec2=02 rec3=034
[0x03] rec0=0f rec1=00 rec2=03 rec3=000
tail 0x21545d2de865a3ddda221 0x42a00088462060003