|
DataMuseum.dkPresents historical artifacts from the history of: Rational R1000/400 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Rational R1000/400 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - download
Length: 6144 (0x1800) Types: Ada Source Notes: 03_class, FILE, R1k_Segment, e3_tag, package body Affectation, seg_0499e2, seg_049a3d, seg_049a60
└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000 └─⟦5a81ac88f⟧ »Space Info Vol 1« └─⟦this⟧ └─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000 └─⟦cfc2e13cd⟧ »Space Info Vol 2« └─⟦this⟧
with Text_Io, The_Hero, The_Place, Complement_Identifier_Array; package body Affectation is procedure Create_Attribute (Item : out Object; An_Attribute : in Attribute.Object; An_Expression : in Expression.Object) is begin Item := (Kind => Single_Attribute, An_Attribute => An_Attribute, New_Value => An_Expression); end Create_Attribute; procedure Create_Hero (Item : out Object; A_Hero : in Detail.Object) is begin Item := (Kind => Hero, New_Hero => A_Hero); end Create_Hero; procedure Create_Place (Item : out Object; A_Place : in Detail.Object) is begin Item := (Kind => Place, New_Place => A_Place); end Create_Place; procedure Run (Item : in Object) is Ok : Boolean; begin case Item.Kind is when Single_Attribute => if Attribute.Is_A_Number (Item.An_Attribute) and Expression.Is_A_Number (Item.New_Value) then Attribute.Affect (Item.An_Attribute, Expression.Evaluate (Item.New_Value), Ok); elsif Attribute.Is_An_Enumerate (Item.An_Attribute) and Expression.Is_An_Enumerate (Item.New_Value) then Attribute.Affect (Item.An_Attribute, Expression.Enumeration (Item.New_Value), Expression.Literal (Item.New_Value), Ok); end if; when Hero => The_Hero.Put (Detail.Index (Item.New_Hero)); Ok := True; when Place => The_Place.Put (Detail.Index (Item.New_Place)); Ok := True; when Unknown => Ok := False; end case; end Run; procedure Show (Item : in Object) is begin Text_Io.Put ("Affectation : Kind : " & Affectation_Kind'Image (Item.Kind)); case Item.Kind is when Single_Attribute => Attribute.Show (Item.An_Attribute); Expression.Show (Item.New_Value); when Hero => The_Hero.Show; Detail.Show (Item.New_Hero); when Place => The_Place.Show; Detail.Show (Item.New_Place); when Unknown => null; end case; end Show; end Affectation;
nblk1=5 nid=5 hdr6=6 [0x00] rec0=23 rec1=00 rec2=01 rec3=02e [0x01] rec0=15 rec1=00 rec2=02 rec3=038 [0x02] rec0=15 rec1=00 rec2=04 rec3=000 [0x03] rec0=04 rec1=00 rec2=05 rec3=000 [0x04] rec0=c0 rec1=00 rec2=00 rec3=100 tail 0x2174e0712865f89a0286a 0x42a00088462060003 Free Block Chain: 0x5: 0000 00 03 00 10 80 0d 65 72 6f 20 3d 3e 20 41 5f 48 ┆ ero => A_H┆ 0x3: 0000 00 00 00 07 80 01 3b 01 00 00 00 20 20 20 20 20 ┆ ; ┆