DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Rational R1000/400

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦77db08d7a⟧ Ada Source

    Length: 6144 (0x1800)
    Types: Ada Source
    Notes: 03_class, FILE, R1k_Segment, e3_tag, procedure Test_Group_Array, seg_0462b1

Derivation

└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000
    └─ ⟦cfc2e13cd⟧ »Space Info Vol 2« 
        └─⟦this⟧ 

E3 Source Code



with Text_Io, Identifier, Group_Array, Complement_Identifier_Array;
use Text_Io;
procedure Test_Group_Array is

    Id : Identifier.Object;
    Ok : Boolean;

begin  
    Complement_Identifier_Array.Put (Identifier.From_String ("gaston"));
    Complement_Identifier_Array.Put (Identifier.From_String ("alfred"));
    Complement_Identifier_Array.Put (Identifier.From_String ("cuisine"));
    Complement_Identifier_Array.Put (Identifier.From_String ("table"));
    Complement_Identifier_Array.Put (Identifier.From_String ("fred"));
    Complement_Identifier_Array.Put (Identifier.From_String ("bureau"));
    Complement_Identifier_Array.Put (Identifier.From_String ("meuble"));
    Complement_Identifier_Array.Put (Identifier.From_String ("chaise"));

    Group_Array.Show;

    Identifier.Put (Id, "meuble");
    Group_Array.Put (Id, Complement_Identifier_Array.Index ("table"), Ok);
    if Ok then
        Put_Line ("Le complement n'etait pas encore insere !");
    else  
        Put_Line ("Le complement etait deja insere !");
    end if;

    Group_Array.Put (Id, Complement_Identifier_Array.Index ("meuble"), Ok);
    if Ok then
        Put_Line ("Le complement n'etait pas encore insere !");
    else  
        Put_Line ("Le complement etait deja insere !");
    end if;

    Group_Array.Put (Id, Complement_Identifier_Array.Index ("table"), Ok);
    if Ok then
        Put_Line ("Le complement n'etait pas encore insere !");
    else  
        Put_Line ("Le complement etait deja insere !");
    end if;

    Group_Array.Put (Id, Complement_Identifier_Array.Index ("chaise"), Ok);
    if Ok then
        Put_Line ("Le complement n'etait pas encore insere !");
    else  
        Put_Line ("Le complement etait deja insere !");
    end if;

    Id := Identifier.From_String ("personnage");
    Group_Array.Put (Id, Complement_Identifier_Array.Index ("alfred"), Ok);
    if Ok then
        Put_Line ("Le complement n'etait pas encore insere !");
    else  
        Put_Line ("Le complement etait deja insere !");
    end if;

    Group_Array.Put (Id, Complement_Identifier_Array.Index ("gaston"), Ok);
    if Ok then
        Put_Line ("Le complement n'etait pas encore insere !");
    else  
        Put_Line ("Le complement etait deja insere !");
    end if;

    Group_Array.Put (Id, Complement_Identifier_Array.Index ("fred"), Ok);
    if Ok then
        Put_Line ("Le complement n'etait pas encore insere !");
    else  
        Put_Line ("Le complement etait deja insere !");
    end if;

    Put_Line ("belong contenant : " &
              Boolean'Image (Group_Array.Belong ("meuble")));
    Put_Line ("belong objet : " & Boolean'Image (Group_Array.Belong ("objet")));
    Put_Line ("belong arme : " & Boolean'Image
                                    (Group_Array.Belong ("personnage")));

    Put_Line ("list_done : " & Boolean'Image (Group_Array.Done ("meuble")));

    Group_Array.Init ("meuble");
    Put_Line ("list_done : " & Boolean'Image (Group_Array.Done ("meuble")));

    Put_Line ("debut");
    Group_Array.Init ("meuble");
    while not Group_Array.Done ("meuble") loop
        Put (Group_Array.Value ("meuble") & ", ");
        Group_Array.Next ("meuble");
    end loop;  
    New_Line;  
    Put_Line ("fin");

    Group_Array.Show;
end Test_Group_Array;

E3 Meta Data

    nblk1=5
    nid=4
    hdr6=8
        [0x00] rec0=19 rec1=00 rec2=01 rec3=00c
        [0x01] rec0=1c rec1=00 rec2=03 rec3=056
        [0x02] rec0=1b rec1=00 rec2=05 rec3=01a
        [0x03] rec0=0f rec1=00 rec2=02 rec3=000
        [0x04] rec0=c0 rec1=00 rec2=00 rec3=100
    tail 0x21748a3a086503b111f35 0x42a00088462060003
Free Block Chain:
  0x4: 0000  00 00 01 88 80 26 20 20 20 20 28 47 72 6f 75 70  ┆     &    (Group┆