DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400 Tapes

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 Tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - metrics - download
Index: B T

⟦8da068959⟧ TextFile

    Length: 1179 (0x49b)
    Types: TextFile
    Names: »B«

Derivation

└─⟦180fe333a⟧ Bits:30000405 8mm tape, Rational 1000, SW CATALOG, 10_20_0
└─⟦180fe333a⟧ Bits:30000537 8mm tape, Rational 1000, SW Catalog 10_20_0
    └─⟦5cb1d1d7f⟧ »DATA« 
        └─⟦3b1ee7bd8⟧ 
            └─⟦this⟧ 

TextFile

with String_Utilities;
package body Line_Utilities is
    package Su renames String_Utilities;

    function Filter (In_Line : String) return String is
        Return_String : String (In_Line'First .. In_Line'Last) := In_Line;
    begin
        for I in Return_String'Range loop
            if Return_String (I) = Ascii.Lf or Return_String (I) = Ascii.Ht then
                Return_String (I) := ' ';
            end if;

        end loop;

        return Su.Strip (Return_String);
    end Filter;

    function Characterize (In_Line : String) return Line_Type is
        Modified_Line : constant String := Filter (In_Line);
    begin

        if Modified_Line'Length = 0 then
            return Blank_Line;
        elsif Modified_Line'Length >= 2 and then
              Modified_Line (Modified_Line'First .. Modified_Line'First + 1) =
                 "--" then
            return Comment_Line;
        else
            for I in Modified_Line'Range loop
                if Modified_Line (I) = ';' then
                    return Contains_Semi;
                end if;
            end loop;
        end if;

        return Other_Type;
    end Characterize;

end Line_Utilities;