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: 3825 (0xef1) Types: TextFile Names: »B«
└─⟦149519bd4⟧ Bits:30000546 8mm tape, Rational 1000, !projects 93-07-13 └─ ⟦124ff5788⟧ »DATA« └─⟦this⟧ └─⟦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⟧ └─⟦a7d1ea751⟧ Bits:30000550 8mm tape, Rational 1000, !users!projects 94_04_11 └─ ⟦129cab021⟧ »DATA« └─⟦e24fb53b7⟧ └─⟦this⟧
separate (Generic_Fact_Base) package body Generic_Fact is Class_Identity : Constant_String.Object := Constant_String.Make (Class_Name); function Slot_Count return Natural is First : Natural := Slot_Names'Pos (Slot_Names'First); Last : Natural := Slot_Names'Pos (Slot_Names'Last); begin return Last - First + 1; end Slot_Count; function As_Fact_Slot_Name (Slot_Name : Slot_Names) return Generic_Fact_Base.Slot_Names is begin return Slot_Names'Pos (Slot_Name) - Slot_Names'Pos (Slot_Names'First) + 1; end As_Fact_Slot_Name; function As_Anonymous (What : Patterns) return Generic_Fact_Base.Patterns is Result : Generic_Fact_Base.Patterns (1 .. Slot_Count); begin for Slot_Name in What'Range loop Result (As_Fact_Slot_Name (Slot_Name)) := What (Slot_Name); end loop; return Result; end As_Anonymous; function As_Anonymous (What : Slots) return Working_Memory.Slots is Result : Working_Memory.Slots (1 .. Slot_Count); begin for Slot_Name in What'Range loop Result (As_Fact_Slot_Name (Slot_Name)) := What (Slot_Name); end loop; return Result; end As_Anonymous; function Exist (What : Patterns) return Query is begin return Query'(Kind => Find, Class => Class_Identity, Size => Slot_Count, Value => As_Anonymous (What)); end Exist; function Not_Any (What : Patterns) return Query is begin return Query'(Kind => Check_No, Class => Class_Identity, Size => Slot_Count, Value => As_Anonymous (What)); end Not_Any; function Get (The_Fact : Object; Slot : Slot_Names) return Integer is begin return Working_Memory.Get (The_Fact, Slot => As_Fact_Slot_Name (Slot)); end Get; function Get (The_Fact : Object) return Slots is Result : Slots; begin for Slot in Slot_Names loop Result (Slot) := Working_Memory.Get (The_Fact, Slot => As_Fact_Slot_Name (Slot)); end loop; return Result; end Get; procedure Add (The_Fact : Slots) is begin Working_Memory.Add (Working_Memory.Make (The_Class => Class_Identity, The_Slots => As_Anonymous (The_Fact))); end Add; procedure Delete (The_Fact : Object) is begin Working_Memory.Delete (The_Fact); end Delete; procedure Change (The_Fact : Object; Value : Slots) is begin Working_Memory.Change (The_Fact, Working_Memory.Make (The_Class => Class_Identity, The_Slots => As_Anonymous (Value))); end Change; procedure Change (The_Fact : Object; The_Slot : Slot_Names; To_Value : Integer) is begin Working_Memory.Change (The_Fact, As_Fact_Slot_Name (The_Slot), To_Value); end Change; procedure Put (The_Fact : Object; Where : Output_Stream.Object) is First : Boolean := True; use Output_Stream; begin Put (Class_Name & "'(", Where); Indent_Right (Where); New_Line (Where); for I in Slot_Names loop if not First then Put_Line (", ", Where); else First := False; end if; Put (Slot_Names'Image (I) & " =>", Where); Put (Attribute_Image (Get (The_Fact, Slot => I)), Where); end loop; Indent_Left (Where); Put_Line (")", Where); end Put; end Generic_Fact;