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

⟦8854ba334⟧ Ada Source

    Length: 6144 (0x1800)
    Types: Ada Source
    Notes: 03_class, FILE, R1k_Segment, e3_tag, package Vstring_Type, seg_005844

Derivation

└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000
    └─ ⟦cfc2e13cd⟧ »Space Info Vol 2« 
        └─⟦this⟧ 

E3 Source Code



with Arithmetic;
use Arithmetic;

package Vstring_Type is
------------------------------------------------------------------------------
-- VString - Variable length, fixed maximum length, strings.
------------------------------------------------------------------------------
-- Copyright 1988 - 1991 by Rational, Santa Clara, California.
--
--                  All Rights Reserved.
--
-- Permission to use, copy, modify, and distribute this software and its
-- documentation for any purpose and without fee is hereby granted,
-- provided that the above copyright notice(s) appear in all copies and that
-- both that copyright notice(s) and this permission notice appear in
-- supporting documentation, and that the name of Rational not be used in
-- advertising or publicity pertaining to distribution of the software
-- without specific, written prior permission.
--
-- Rational disclaims all warranties with regard to this software, including
-- all implied warranties of merchantability and fitness, in no event shall
-- Rational be liable for any special, indirect or consequential damages or
-- any damages whatsoever resulting from loss of use, data or profits, whether
-- in an action of contract, negligence or other tortious action, arising out
-- of or in connection with the use or performance of this software.
------------------------------------------------------------------------------

    type E_String         is array (S_Positive range <>) of Character;
    type E_String_Pointer is access E_String;

    type E_String_Array is array (S_Positive range <>) of E_String_Pointer;
    type E_String_List  is access E_String_Array;

    function To_String (Estr : E_String) return String;
------------------------------------------------------------------------------
-- Changes the E_String into a normal Ada string.  Truncates the E_String,
-- if necessary, in order to create a maximally sized Ada String.  (This is
-- in the case where Integer'Size is 16 bits.)
------------------------------------------------------------------------------

    type Vstring_Data (Maximum_Length : S_Natural) is
    ----Version of string for stack and array allocation.
        record
            Length : S_Natural := 0;                 -- Current string length
            Chars  : E_String (1 .. Maximum_Length); -- Current string contents
        end record;

    type Vstring is access Vstring_Data;
    ----Version of string for heap allocation.

    None_Vstring : constant Vstring := null;

    type Vstring_Array is array (S_Positive range <>) of Vstring;
    type Vstring_List  is access Vstring_Array;

----VStrings hold 0..N characters.  N is determined when the string is
--  allocated.
--
--  Data in VStrings consists of Chars(1..N).  Char(1) is valid if the length
--  of the VString is in the 1..N range.  Char(2) is valid if the length of
--  the VString is in the 2..N range.  Etc.
--
--  Length is always in the 0..Maximum_Length range.

end Vstring_Type;

E3 Meta Data

    nblk1=5
    nid=4
    hdr6=8
        [0x00] rec0=16 rec1=00 rec2=01 rec3=036
        [0x01] rec0=11 rec1=00 rec2=02 rec3=02a
        [0x02] rec0=19 rec1=00 rec2=05 rec3=01e
        [0x03] rec0=03 rec1=00 rec2=03 rec3=001
        [0x04] rec0=00 rec1=00 rec2=00 rec3=008
    tail 0x21700ab5881978f28baf8 0x42a00088462063203
Free Block Chain:
  0x4: 0000  00 00 00 38 80 1b 68 65 20 30 2e 2e 4d 61 78 69  ┆   8  he 0..Maxi┆