Yurttas/PL/IL/Ada-95/F/04/03/00/gardener 00.adb

From ZCubes Wiki
Jump to navigation Jump to search
 1--
 2-- Copyright (C) 2000
 3-- All Rights Reserved. Salih Yurttas, ZCubes, BitsOfCode Software Systems, Inc..
 4--
 5-- Permission to use, copy, modify, and distribute this 
 6-- software and its documentation for EDUCATIONAL purposes
 7-- and without fee is hereby granted provided that this 
 8-- copyright notice appears in all copies. 
 9-- 
10-- 
11 
12-- date   : September 1, 2000.
13-- author : Salih Yurttas.
14
15-- purpose : To choose a specific garden with
16--           appropriate plants with choice of positioning.
17--           [ abstract factory design is used ]
18
19-- gardener_00.adb
20
21
22with Garden_Planting_P; use Garden_Planting_P;
23
24procedure Gardener_00 is
25
26  A_P_V_Choice : Garden;
27
28begin
29
30  loop
31
32    A_P_V_Choice := Get_Garden;
33
34    case A_P_V_Choice is
35
36      when A => Annual_Planting;
37
38      when P => Perennial_Planting;
39
40      when V => Veggie_Planting;
41
42      when E => exit;
43
44    end case;
45
46  end loop;
47
48end Gardener_00;