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 - downloadIndex: ┃ B T ┃
Length: 2781 (0xadd) Types: TextFile Names: »B«
└─⟦a7d1ea751⟧ Bits:30000550 8mm tape, Rational 1000, !users!projects 94_04_11 └─ ⟦129cab021⟧ »DATA« └─⟦this⟧ └─⟦f64eaa120⟧ Bits:30000752 8mm tape, Rational 1000, !projects 93 02 16 └─ ⟦6f12a12be⟧ »DATA« └─⟦this⟧ └─⟦2f6cfab89⟧ Bits:30000547 8mm tape, Rational 1000, !projects 94-01-04 └─ ⟦d65440be7⟧ »DATA« └─⟦this⟧
with Text_Io; package body Control is procedure Set (The_Object : in out Object; To_Value : Integer) is begin if To_Value < Minimum then case The_Object.Mode is when Checked => raise Underflow; when Constrained | Circulary => The_Object.Value := Minimum; end case; elsif To_Value > Maximum then case The_Object.Mode is when Checked => raise Overflow; when Constrained | Circulary => The_Object.Value := Maximum; end case; else The_Object.Value := To_Value; end if; end Set; procedure Set (The_Object : in out Object; To_Mode : Running_Modes) is begin The_Object.Mode := To_Mode; end Set; procedure Reset (The_Object : in out Object) is begin The_Object.Value := Default; end Reset; procedure Up_One (The_Object : in out Object) is begin if The_Object.Value = Maximum then case The_Object.Mode is when Checked => raise Overflow; when Constrained => null; when Circulary => The_Object.Value := Minimum; end case; else The_Object.Value := The_Object.Value + 1; end if; end Up_One; procedure Up (The_Object : in out Object; Count : Positive := 1) is begin for I in 1 .. Count loop Up_One (The_Object); end loop; end Up; procedure Down_One (The_Object : in out Object) is begin if The_Object.Value = Minimum then case The_Object.Mode is when Checked => raise Underflow; when Constrained => null; when Circulary => The_Object.Value := Maximum; end case; else The_Object.Value := The_Object.Value - 1; end if; end Down_One; procedure Down (The_Object : in out Object; Count : Positive := 1) is begin for I in 1 .. Count loop Down_One (The_Object); end loop; end Down; procedure Put (The_Object : Object) is begin Text_Io.Put_Line (Running_Modes'Image (The_Object.Mode) & " counter from " & Integer'Image (Minimum) & " to " & Integer'Image (Maximum) & " set to value: " & Integer'Image (The_Object.Value)); end Put; function Get (The_Object : Object) return Running_Modes is begin return The_Object.Mode; end Get; end Control;