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

⟦12bf37a24⟧ Ada Source

    Length: 3072 (0xc00)
    Types: Ada Source
    Notes: 03_class, FILE, R1k_Segment, e3_tag, package body Tampon, seg_04f002

Derivation

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

E3 Source Code



package body Tampon is
    Tab_Tampon : array (1 .. Taille) of Element;
    Entree : Integer range 1 .. Taille;
    Sortie : Integer range 1 .. Taille;
    Nb_Elements : Integer range 1 .. Taille;
    procedure Creer_Tampon (Taille, E : Element) is
    begin
        Entree := 1;
        Sortie := 1;
        Nb_Elements := 0;
    end Creer_Tampon;


    procedure Entrer_Element (E : Element) is
    begin
        if Nb_Elements < Taille then
            Tab_Tampon (Entree) := E;
            Nb_Elements := Nb_Elements + 1;
            if Entree = Taille then
                Entree := 1;
            else
                Entree := Entree + 1;
            end if;
        else
            Put_Line ("Tampon plein");
        end if;
    end Entrer_Element;


    function Sortir_Element return Element is
        E : Element;
    begin
        if Nb_Elements = 0 then
            Put_Line ("Tampon vide");
        else
            Nb_Elements := Nb_Elements - 1;
            E := Tab_Tampon (Sortie);
            if Sortie = Taille then
                Sortie := 1;
            else
                Sortie := Sortie + 1;
            end if;
            return E;
        end if;
    end Sortir_Element;


    procedure Lister_Tampon is
    begin
        for I in 1 .. Taille loop
            New_Line;
            Put ("Element");
        end loop;
    end Lister_Tampon;


    procedure Vider_Tampon is
    begin
        Entree := 1;
        Sortie := 1;
        Nb_Elements := 0;
    end Vider_Tampon;
end Tampon;

E3 Meta Data

    nblk1=2
    nid=0
    hdr6=4
        [0x00] rec0=25 rec1=00 rec2=01 rec3=030
        [0x01] rec0=1c rec1=00 rec2=02 rec3=001
    tail 0x2154a5a8a87736132f8e1 0x42a00088462060003