|
|
DataMuseum.dkPresents historical artifacts from the history of: Rational R1000/400 Tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Rational R1000/400 Tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: B T
Length: 2211 (0x8a3)
Types: TextFile
Names: »B«
└─⟦a7d1ea751⟧ Bits:30000550 8mm tape, Rational 1000, !users!projects 94_04_11
└─⟦129cab021⟧ »DATA«
└─⟦this⟧
└─⟦2f6cfab89⟧ Bits:30000547 8mm tape, Rational 1000, !projects 94-01-04
└─⟦d65440be7⟧ »DATA«
└─⟦this⟧
with Pkg_Synchro;
package body Pkg_Agent_Generic is
task body Agent is
The_Periode : Duration;
The_Count : Natural;
The_Object : Object;
Next_Operation : Time;
Done : Boolean := False;
begin
loop
accept Cycle
(Periode : Duration; N : Natural; Obj : in out Object) do
The_Periode := Periode;
The_Count := N;
The_Object := Obj;
end Cycle;
Pkg_Synchro.Synchro.Start;
Next_Operation := Clock;
loop
Next_Operation := Next_Operation + The_Periode;
select
accept Stop do
Done := True;
end Stop;
or
accept Suspend;
accept Resume;
or
delay Next_Operation - Calendar.Clock;
end select;
Operation (The_Object);
exit when Done or The_Count = 1;
The_Count := The_Count - 1;
end loop;
exit when Done or The_Count = 1;
end loop;
select
accept Stop;
or
terminate;
end select;
end Agent;
procedure Cycle (The_Pool : Pool;
The_Periodes : Tableau_Periode;
The_Nbr_Cycle : Tableau_Nbr;
The_Objects : in out Tableau_Object) is
begin
for I in 1 .. The_Pool'Last loop
The_Pool (I).Cycle
(The_Periodes (I), The_Nbr_Cycle (I), The_Objects (I));
end loop;
end Cycle;
procedure Stop (The_Pool : Pool) is
begin
for I in 1 .. The_Pool'Last loop
The_Pool (I).Stop;
end loop;
end Stop;
procedure Suspend (The_Pool : Pool) is
begin
for I in 1 .. The_Pool'Last loop
The_Pool (I).Suspend;
end loop;
end Suspend;
procedure Resume (The_Pool : Pool) is
begin
for I in 1 .. The_Pool'Last loop
The_Pool (I).Resume;
end loop;
end Resume;
end Pkg_Agent_Generic;