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

⟦166498f24⟧ Ada Source

    Length: 5120 (0x1400)
    Types: Ada Source
    Notes: 03_class, FILE, R1k_Segment, e3_tag, package Bounded_String, seg_042764

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 Bounded_String is

    subtype String_Length is Natural;

    type Variable_String (Maximum_Length : String_Length) is private;
    -- initialized to have a length of 0

    procedure Copy (Target : in out Variable_String; Source : Variable_String);
    procedure Copy (Target : in out Variable_String; Source : String);
    procedure Copy (Target : in out Variable_String; Source : Character);

    procedure Move (Target : in out Variable_String;
                    Source : in out Variable_String);

    function Image (V : Variable_String) return String;

    -- Value function with maximum length = current length
    function Value (S : String) return Variable_String;

    -- Value function with specified maximum length
    function Value (S : String; Max_Length : Natural) return Variable_String;
    pragma Inline (Image);

    procedure Free (V : in out Variable_String);

    procedure Append (Target : in out Variable_String;
                      Source : Variable_String);

    procedure Append (Target : in out Variable_String; Source : String);

    procedure Append (Target : in out Variable_String; Source : Character);

    procedure Append (Target : in out Variable_String;
                      Source : Character;
                      Count : Natural);

    procedure Insert (Target : in out Variable_String;
                      At_Pos : Positive;
                      Source : Variable_String);

    procedure Insert (Target : in out Variable_String;
                      At_Pos : Positive;
                      Source : String);

    procedure Insert (Target : in out Variable_String;
                      At_Pos : Positive;
                      Source : Character);

    procedure Insert (Target : in out Variable_String;
                      At_Pos : Positive;
                      Source : Character;
                      Count : Natural);

    procedure Delete (Target : in out Variable_String;
                      At_Pos : Positive;
                      Count : Natural := 1);

    procedure Replace (Target : in out Variable_String;
                       At_Pos : Positive;
                       Source : Character);

    procedure Replace (Target : in out Variable_String;
                       At_Pos : Positive;
                       Source : Character;
                       Count : Natural);

    procedure Replace (Target : in out Variable_String;
                       At_Pos : Positive;
                       Source : String);

    procedure Replace (Target : in out Variable_String;
                       At_Pos : Positive;
                       Source : Variable_String);

    -- Truncate or extend with fill
    procedure Set_Length (Target : in out Variable_String;
                          New_Length : Natural;
                          Fill_With : Character := ' ');

    -- Get information about or contents of a string
    function Length (Source : Variable_String) return Natural;
    function Char_At (Source : Variable_String; At_Pos : Positive)
                     return Character;

    function Extract (Source : Variable_String;
                      Start_Pos : Positive;
                      End_Pos : Natural) return String;

    -- get the allocated length of the string
    function Max_Length (Source : Variable_String) return Natural;
    pragma Inline (Length);
    pragma Inline (Char_At);
    pragma Inline (Max_Length);
private
    type Variable_String (Maximum_Length : String_Length) is
        record
            Length : String_Length := 0;
            Contents : String (1 .. Maximum_Length);
        end record;

end Bounded_String;


E3 Meta Data

    nblk1=4
    nid=0
    hdr6=8
        [0x00] rec0=1c rec1=00 rec2=01 rec3=01c
        [0x01] rec0=1b rec1=00 rec2=02 rec3=048
        [0x02] rec0=1a rec1=00 rec2=03 rec3=056
        [0x03] rec0=17 rec1=00 rec2=04 rec3=000
    tail 0x2153dad78862f68f94b5f 0x42a00088462060003