|
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: 7168 (0x1c00) Types: Ada Source Notes: 03_class, FILE, R1k_Segment, e3_tag, procedure Test_Arbres, seg_045705, seg_045e0d, seg_046949, seg_04840f
└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000 └─⟦5a81ac88f⟧ »Space Info Vol 1« └─⟦this⟧ └─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000 └─⟦cfc2e13cd⟧ »Space Info Vol 2« └─⟦this⟧
with Text_Io, Nos_Arbres, String_Utilities, Test_Arbres_Bis; procedure Test_Arbres is --type Valeur is -- record -- Chaine : String (1 .. 8); -- Int : Integer := 0; --end record; --function Difference (P, Q : Valeur) return Integer; --package Arbre is new Nos_Arbres (Valeur); --Un_Arbre : Arbre.Object; --Iter : Arbre.Iterator; Found : Boolean; Search_Valeur, Val, Val_1, Val_2, Val_3, Val_4, Val_5 : Test_Arbres_Bis.Valeur; Val1, Val2, Val3, Val4, Val5 : Test_Arbres_Bis.Valeur; El, Elem : Test_Arbres_Bis.Valeur; --function Differe (X, Y : String) return Integer is --begin -- if String_Utilities.Less_Than (X, Y) then -- return -1; --elsif String_Utilities.Less_Than (Y, X) then -- return 1; --else -- return 0; --end if; --end Differe; --function Difference (P, Q : Valeur) return Integer is --begin -- return Differe (P.Chaine, Q.Chaine); --end Difference; --use Arbre; procedure Search is begin Test_Arbres_Bis.Find (Search_Valeur, Found); if not Found then Text_Io.Put_Line ("element non trouve."); else Text_Io.Put ("element trouve"); Text_Io.Put_Line (Integer'Image (Search_Valeur.Int)); end if; end Search; begin -- Un_Arbre := Create_Tree; Val.Chaine := "valeur 1"; Val.Int := 1; Test_Arbres_Bis.Add (Val); Val.Chaine := "valeur 2"; Val.Int := 2; Test_Arbres_Bis.Add (Val); Val.Chaine := "valeur 3"; Val.Int := 3; Test_Arbres_Bis.Add (Val); Val.Chaine := "valeur 4"; Val.Int := 4; Test_Arbres_Bis.Add (Val); Val.Chaine := "valeur 5"; Val.Int := 5; Test_Arbres_Bis.Add (Val); Val.Chaine := "valeur 5"; Val.Int := 100; Test_Arbres_Bis.Add (Val); --Add (Val_1, Un_Arbre); --Add (Val_2, Un_Arbre); --Add (Val_3, Un_Arbre); --Add (Val_4, Un_Arbre); --Add (Val_5, Un_Arbre); Text_Io.Put_Line ("ok add"); Search_Valeur.Chaine := "valeur 1"; Search; Search_Valeur.Chaine := "valeur 2"; Search; Search_Valeur.Chaine := "valeur 3"; Search; Search_Valeur.Chaine := "valeur 4"; Search; Search_Valeur.Chaine := "valeur 6"; Search; Search_Valeur.Chaine := "valeur 5"; Search; --Find (Search_Valeur,un_arbre, Found); --if not Found then -- Text_Io.Put_Line ("element non trouve."); --else -- Text_Io.Put ("element trouve"); --Text_Io.Put_Line (Integer'Image (Search_Valeur.Int)); --end if; --Text_Io.Put_Line (Val_3.Chaine); -- Extract (Un_Arbre, Val1); -- Text_Io.Put_Line (Val1.Chaine); -- Extract (Un_Arbre, Val2); -- Text_Io.Put_Line (Val2.Chaine); -- Extract (Un_Arbre, Val3); -- Text_Io.Put_Line (Val3.Chaine); -- Extract (Un_Arbre, Val4); -- Text_Io.Put_Line (Val4.Chaine); -- Extract (Un_Arbre, Val5); -- Text_Io.Put_Line (Val5.Chaine); Text_Io.Put_Line ("iteration !"); -- First_Iteration (Un_Arbre, Iter, Val1); -- Text_Io.Put_Line (Val1.Chaine); -- Val1.Chaine := "aaaaaaaa"; --Iter := Create_Iterator (Un_Arbre); --while (not End_Iteration (Iter)) loop -- Iterate (Iter, Val1); --if Val1.Chaine = "valeur 4" then -- Text_Io.Put_Line ("++++++++++++++valeur trouvee : "); --else -- Text_Io.Put_Line ("valeur non trouvee."); --end if; --Text_Io.Put_Line (Val1.Chaine); --end loop; --Iter := Create_Iterator (Un_Arbre); --while (not End_Iteration (Iter)) loop -- Iterate (Iter, Val1); --if Val1.Chaine = "valeur 4" then -- Text_Io.Put_Line ("++++++++++++++valeur trouvee : "); --else -- Text_Io.Put_Line ("valeur non trouvee."); --end if; --Text_Io.Put_Line (Val1.Chaine); --end loop; exception when others => Text_Io.Put_Line ("erreur test_arbre"); end Test_Arbres;
nblk1=6 nid=0 hdr6=c [0x00] rec0=24 rec1=00 rec2=01 rec3=022 [0x01] rec0=27 rec1=00 rec2=03 rec3=038 [0x02] rec0=23 rec1=00 rec2=05 rec3=036 [0x03] rec0=01 rec1=00 rec2=06 rec3=02c [0x04] rec0=1f rec1=00 rec2=04 rec3=04a [0x05] rec0=07 rec1=00 rec2=02 rec3=001 tail 0x21541c9e6864b4f02e3f8 0x42a00088462060003