Annotated Ada Reference ManualLegal Information
Contents   Index   References   Search   Previous   Next 

A.18.5 The Package Containers.Hashed_Maps

Static Semantics

1/2
{AI95-00302-03} The generic library package Containers.Hashed_Maps has the following declaration: 
2/2
generic
   type Key_Type is private;
   type Element_Type is private;
   with function Hash (Key : Key_Type) return Hash_Type;
   with function Equivalent_Keys (Left, Right : Key_Type)
      return Boolean;
   with function "=" (Left, Right : Element_Type)
      return Boolean is <>;
package Ada.Containers.Hashed_Maps is
   pragma Preelaborate(Hashed_Maps);
3/2
   type Map is tagged private;
   pragma Preelaborable_Initialization(Map);
4/2
   type Cursor is private;
   pragma Preelaborable_Initialization(Cursor);
5/2
   Empty_Map : constant Map;
6/2
   No_Element : constant Cursor;
7/2
   function "=" (Left, Right : Map) return Boolean;
8/2
   function Capacity (Container : Map) return Count_Type;
9/2
   procedure Reserve_Capacity (Container : in out Map;
                               Capacity  : in     Count_Type);
10/2
   function Length (Container : Map) return Count_Type;
11/2
   function Is_Empty (Container : Map) return Boolean;
12/2
   procedure Clear (Container : in out Map);
13/2
   function Key (Position : Cursor) return Key_Type;
14/2
   function Element (Position : Cursor) return Element_Type;
15/2
   procedure Replace_Element (Container : in out Map;
                              Position  : in     Cursor;
                              New_Item  : in     Element_Type);
16/2
   procedure Query_Element
     (Position : in Cursor;
      Process  : not null access procedure (Key     : in Key_Type;
                                            Element : in Element_Type));
17/2
   procedure Update_Element
     (Container : in out Map;
      Position  : in     Cursor;
      Process   : not null access procedure
                      (Key     : in     Key_Type;
                       Element : in out Element_Type));
18/2
   procedure Move (Target : in out Map;
                   Source : in out Map);
19/2
   procedure Insert (Container : in out Map;
                     Key       : in     Key_Type;
                     New_Item  : in     Element_Type;
                     Position  :    out Cursor;
                     Inserted  :    out Boolean);
20/2
   procedure Insert (Container : in out Map;
    &