Natools

Diff
Login

Differences From Artifact [3f158be03d]:

To Artifact [e6b2a37ac4]:


1
2
3
4

5
6
7
8
9
10
11
12
13
14
15
16
17
18












19
--  Generated at 2014-10-03 21:03:09 +0000 by Natools.Static_Hash_Maps
--  from src/natools-s_expressions-templates-dates-maps.sx

with Natools.Static_Maps.S_Expressions.Templates.Dates.Cmds;


package body Natools.Static_Maps.S_Expressions.Templates.Dates is

   function Main (Key : String) return Main_Command is
      N : constant Natural
        := Natools.Static_Maps.S_Expressions.Templates.Dates.Cmds.Hash (Key);
   begin
      if Map_1_Keys (N).all = Key then
         return Map_1_Elements (N);
      else
         return Error;
      end if;
   end Main;













end Natools.Static_Maps.S_Expressions.Templates.Dates;
|



>














>
>
>
>
>
>
>
>
>
>
>
>

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
--  Generated at 2015-06-24 18:19:13 +0000 by Natools.Static_Hash_Maps
--  from src/natools-s_expressions-templates-dates-maps.sx

with Natools.Static_Maps.S_Expressions.Templates.Dates.Cmds;
with Natools.Static_Maps.S_Expressions.Templates.Dates.Zones;

package body Natools.Static_Maps.S_Expressions.Templates.Dates is

   function Main (Key : String) return Main_Command is
      N : constant Natural
        := Natools.Static_Maps.S_Expressions.Templates.Dates.Cmds.Hash (Key);
   begin
      if Map_1_Keys (N).all = Key then
         return Map_1_Elements (N);
      else
         return Error;
      end if;
   end Main;


   function To_Time_Offset (Key : String) return Integer is
      N : constant Natural
        := Natools.Static_Maps.S_Expressions.Templates.Dates.Zones.Hash (Key);
   begin
      if Map_2_Keys (N).all = Key then
         return Map_2_Elements (N);
      else
         raise Constraint_Error with "Key """ & Key & """ not in map";
      end if;
   end To_Time_Offset;

end Natools.Static_Maps.S_Expressions.Templates.Dates;