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

⟦740e7bd1b⟧ Ada Source

    Length: 7168 (0x1c00)
    Types: Ada Source
    Notes: 03_class, FILE, R1k_Segment, e3_tag, procedure Test_Order, seg_045f5e

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, Order, Identifier, Moving_String,
     Group_Array, Complement_Identifier_Array;
use Text_Io, Order;
procedure Test_Order is

    O, O1 : Object;
    Ia, Ia2 : Index_Array;
    Id : Identifier.Object;
    Ok : Boolean;

begin
    Put_Line ("rempli le complemnt identifier array");
    Complement_Identifier_Array.Put (Identifier.From_String ("courir"));
    Complement_Identifier_Array.Put (Identifier.From_String ("chambre"));
    Complement_Identifier_Array.Put (Identifier.From_String ("salon"));
    Complement_Identifier_Array.Put (Identifier.From_String ("cuisine"));
    Complement_Identifier_Array.Put (Identifier.From_String ("aller"));
    Complement_Identifier_Array.Put (Identifier.From_String ("de"));
    Complement_Identifier_Array.Put (Identifier.From_String ("nord"));
    Complement_Identifier_Array.Show;

    Id := Identifier.From_String ("salle");
    Put_Line ("rempli group array");
    Put_Line (Identifier.Image (Id) & " " & " " &
              Natural'Image (Complement_Identifier_Array.Index ("chambre")));
    Group_Array.Put (Id, Complement_Identifier_Array.Index ("chambre"), Ok);
    Group_Array.Put (Id, Complement_Identifier_Array.Index ("salon"), Ok);
    Group_Array.Put (Id, Complement_Identifier_Array.Index ("cuisine"), Ok);
    Group_Array.Show;

    Put_Line ("show vide");
    Show (O);

    Put_Line ("put complement");
    Put_Place (O, Moving_String.From_String ("cuisine"));

    Put_First_Complement (O, Moving_String.From_String ("aller"));

    Put_Second_Complement (O, Moving_String.From_String ("nord"));

    Put_Third_Complement (O, Moving_String.From_String ("de"));

    Put_Fourth_Complement (O, Moving_String.From_String ("salle"));

    Put_Place (O1, Moving_String.From_String ("cuisine"));

    Put_First_Complement (O1, Moving_String.From_String ("aller"));

    Put_Second_Complement (O1, Moving_String.From_String ("nord"));

    Put_Third_Complement (O1, Moving_String.From_String ("salle"));

    Put_Fourth_Complement (O1, Moving_String.From_String (""));


    Put_Line ("complement " & "D" & Complement (O, 1) & Complement (O, 2) &
              Complement (O, 3) & Complement (O, 4) & Complement (O, 5) & "F");

    Put_Line ("image " & Image (O));

    Put_Line ("show plein");
    Show (O);
    Show (O1);


    Put_Line ("redirection ");
    Ia2 := Redirection (O);
    Put_Line ("image de ia2 : " & Index'Image (Ia2 (1)) & " " &
              Index'Image (Ia2 (2)) & " " & Index'Image (Ia2 (3)) & " " &
              Index'Image (Ia2 (4)) & " " & Index'Image (Ia2 (5)));

    Put_Line ("redirected_complement " & "D" & Redirected_Complement (O, 2) &
              " " & Redirected_Complement (O, 1) & " " &
              Redirected_Complement (O, 3) & " " &
              Redirected_Complement (O, 4) & " " &
              Redirected_Complement (O, 5) & "F");
    Put_Line ("redirected_complement " & "D" &
              Redirected_Complement (O, 2) & Redirected_Complement (O, 1) &
              Redirected_Complement (O, 3) & Redirected_Complement (O, 4) &
              Redirected_Complement (O, 5) & "F");

    Put_Line ("complement " & "D" & Complement (O, 2) & " " &
              Complement (O, 1) & " " & Complement (O, 3) & " " &
              Complement (O, 4) & " " & Complement (O, 5) & "F");
    Put_Line ("complement " & "D" & Complement (O, 2) & Complement (O, 1) &
              Complement (O, 3) & Complement (O, 4) & Complement (O, 5) & "F");

    Put_Line ("contain aller " & Boolean'Image
                                    (Contains_Complement (O, "aller")));
    Put_Line ("contain qller " & Boolean'Image
                                    (Contains_Complement (O, "qller")));

    Put_Line ("position de " & Natural'Image (Complement_Position (O, "de")));
    Put_Line ("position des " & Natural'Image (Complement_Position (O, "des")));

    Put_Line
       ("redirection aller nord salle salle -> 5 pour aller nord de salle");
    Make_Redirection (O1, "salle", 5);
    Show (O1);
    Put_Line ("complement salle (5) de o1 : " & Complement (O1, 5));
    Put_Line ("redirected complement salle (5) de o1 : " &
              Redirected_Complement (O1, 5));


    Put_Line ("put redirection");
    Ia := (1, 3, 4, 5, 2);
    Put_Redirection (O, Ia);
    Show (O);

    --Put_Line ("show apres free");
    --Free (O);
    --Show (O);

end Test_Order;

E3 Meta Data

    nblk1=6
    nid=6
    hdr6=a
        [0x00] rec0=19 rec1=00 rec2=01 rec3=060
        [0x01] rec0=1b rec1=00 rec2=04 rec3=038
        [0x02] rec0=1a rec1=00 rec2=03 rec3=05c
        [0x03] rec0=14 rec1=00 rec2=02 rec3=012
        [0x04] rec0=12 rec1=00 rec2=05 rec3=000
        [0x05] rec0=43 rec1=22 rec2=99 rec3=717
    tail 0x217481b90864d57b446fc 0x42a00088462060003
Free Block Chain:
  0x6: 0000  00 00 00 87 80 1b 69 72 65 63 74 65 64 5f 43 6f  ┆      irected_Co┆