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 - download
Index: ┃ B T

⟦f565fd3e0⟧ TextFile

    Length: 2030 (0x7ee)
    Types: TextFile
    Names: »B«

Derivation

└─⟦149519bd4⟧ Bits:30000546 8mm tape, Rational 1000, !projects 93-07-13
    └─ ⟦124ff5788⟧ »DATA« 
        └─⟦this⟧ 

TextFile

with Message_Interchange;
with Signature;
with String_Utilities;
with Unchecked_Deallocation;
package body Method is

    use Bs;

    Sep : Character renames Message_Interchange.Separator;

    function Sup (S : String) return String renames String_Utilities.Upper_Case;

    function Create (Name : String; Signature : Standard.Signature.Object)
                    return Method.Object is
    begin
        return Object'(Name => Bs.Value (Sup (Name)), Signature => Signature);
    end Create;


    function Image (Method : Standard.Method.Object) return String is
    begin
        return Bs.Image (Method.Name) & Sep &
                  Signature.Image (Method.Signature);
    end Image;


    function Value (Of_String : String) return Method.Object is
        S : String renames Of_String;
        Signature : Positive := Of_String'First;
    begin
        loop
            exit when S (Signature) = Sep;
            Signature := Signature + 1;
        end loop;

        return Object'(Name => Bs.Value (Sup (S (S'First .. Signature - 1))),
                       Signature => Standard.Signature.Value
                                       (S (Signature + 1 .. S'Last)));
    end Value;


    function Is_Equal (Left, Right : Method.Object) return Boolean is
    begin
        return Left.Name = Right.Name and Signature.Is_Equal
                                             (Left.Signature, Right.Signature);
    end Is_Equal;


    function Is_Compatible (Left, Right : Method.Object) return Boolean is
    begin
        return Left.Name = Right.Name and Signature.Is_Compatible
                                             (Left.Signature, Right.Signature);
    end Is_Compatible;


    function Get_Name (Method : Standard.Method.Object) return String is
    begin
        return Bs.Image (Method.Name);
    end Get_Name;


    function Get_Signature (Method : Standard.Method.Object)
                           return Signature.Object is
    begin
        return Method.Signature;
    end Get_Signature;
end Method;