|
|
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 Dictionnary, seg_0468a5
└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000
└─⟦5a81ac88f⟧ »Space Info Vol 1«
└─⟦this⟧
with Generic_Binary_Tree, Unbounded_String;
package body Dictionnary is
package Unlimited_String is new Unbounded_String (10);
function "<" (C1, C2 : Unlimited_String.Variable_String) return Boolean;
function Are_Equal
(C1, C2 : Unlimited_String.Variable_String) return Boolean;
procedure Copy (Source : in Unlimited_String.Variable_String;
Target : in out Unlimited_String.Variable_String);
package Word_Tree is new Generic_Binary_Tree
(Unlimited_String.Variable_String,
"<", Are_Equal, Copy);
Verbs_Dictionnary : Word_Tree.Object;
Complements_Dictionnary : Word_Tree.Object;
Storage_Kind : Kind_Of_Storage;
function "<" (C1, C2 : Unlimited_String.Variable_String) return Boolean is
begin
return (Unlimited_String.Image (C1) < Unlimited_String.Image (C2));
end "<";
function Are_Equal
(C1, C2 : Unlimited_String.Variable_String) return Boolean is
begin
return (Unlimited_String.Image (C1) = Unlimited_String.Image (C2));
end Are_Equal;
procedure Copy (Source : in Unlimited_String.Variable_String;
Target : in out Unlimited_String.Variable_String) is
begin
Unlimited_String.Copy (Target, Source);
end Copy;
procedure Set_Kind_Of_Storage (Kind : Kind_Of_Storage) is
begin
Storage_Kind := Kind;
end Set_Kind_Of_Storage;
procedure Insert (S : String) is
begin
case Storage_Kind is
when Verb =>
Word_Tree.Insert (Verbs_Dictionnary,
Unlimited_String.Value (S));
when Complement =>
Word_Tree.Insert (Complements_Dictionnary,
Unlimited_String.Value (S));
end case;
end Insert;
function Is_Verb (S : String) return Boolean is
begin
return Word_Tree.Exists (Verbs_Dictionnary, Unlimited_String.Value (S));
end Is_Verb;
function Is_Complement (S : String) return Boolean is
begin
return Word_Tree.Exists (Complements_Dictionnary,
Unlimited_String.Value (S));
end Is_Complement;
end Dictionnary;
nblk1=4
nid=3
hdr6=6
[0x00] rec0=1e rec1=00 rec2=01 rec3=008
[0x01] rec0=1c rec1=00 rec2=04 rec3=038
[0x02] rec0=0c rec1=00 rec2=02 rec3=000
[0x03] rec0=03 rec1=6e rec2=d1 rec3=742
tail 0x215433c7086515c6b8ce6 0x42a00088462060003
Free Block Chain:
0x3: 0000 00 00 01 2a 80 19 69 6d 69 74 65 64 5f 53 74 72 ┆ * imited_Str┆