ALMaSS Hare ODDox  1.1
The hare model description following ODdox protocol
PotatoesIndustry.h
Go to the documentation of this file.
1 //
2 // Potatoes.h
3 //
4 /*
5 *******************************************************************************************************
6 Copyright (c) 2011, Christopher John Topping, Aarhus University
7 All rights reserved.
8 
9 Redistribution and use in source and binary forms, with or without modification, are permitted provided
10 that the following conditions are met:
11 
12 Redistributions of source code must retain the above copyright notice, this list of conditions and the
13 following disclaimer.
14 Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
15 the following disclaimer in the documentation and/or other materials provided with the distribution.
16 
17 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
18 IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
19 FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS
20 BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
21 BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
22 BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
23 LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
24 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 ********************************************************************************************************
26 */
27 #ifndef POTATOESIND_H
28 #define POTATOESIND_H
29 
30 #define POTATOESIND_BASE 16950
31 #define POT_SLURRY_DATE m_field->m_user[0]
32 #define POT_HERBI_DATE m_field->m_user[1]
33 #define POT_STRIG_DATE m_field->m_user[2]
34 #define POT_HILL_DATE m_field->m_user[3]
35 #define POT_DID_TREAT m_field->m_user[4]
36 #define POT_DID_HILL m_field->m_user[5]
37 #define POT_WATER_DATE m_field->m_user[6]
38 #define POT_FUNGI_DATE m_field->m_user[7]
39 
40 typedef enum {
41  pi_start = 1, // Compulsory, start event must always be 1 (one).
68 
69 
70 
71 class PotatoesIndustry: public Crop
72 {
73 public:
74  bool Do( Farm *a_farm, LE *a_field, FarmEvent *a_ev );
76  {
77  m_first_date=g_date->DayInYear(1,11);
78  }
79 };
80 
81 #endif // POTATOESIND_H
pi_start
Definition: PotatoesIndustry.h:41
pi_fa_npk
Definition: PotatoesIndustry.h:47
FarmEvent
A struct to hold the information required to trigger a farm event.
Definition: farm.h:463
pi_strigling_one
Definition: PotatoesIndustry.h:52
pi_fp_npk
Definition: PotatoesIndustry.h:48
pi_hilling
Definition: PotatoesIndustry.h:55
pi_spring_sow
Definition: PotatoesIndustry.h:46
pi_herbi_three
Definition: PotatoesIndustry.h:51
Crop::m_first_date
int m_first_date
Definition: farm.h:540
Crop
The base class for all crops.
Definition: farm.h:534
PotatoesIndToDo
PotatoesIndToDo
Definition: PotatoesIndustry.h:40
PotatoesIndustry::Do
bool Do(Farm *a_farm, LE *a_field, FarmEvent *a_ev)
Definition: PotatoesIndustry.cpp:37
PotatoesIndustry::PotatoesIndustry
PotatoesIndustry()
Definition: PotatoesIndustry.h:75
pi_spring_harrow
Definition: PotatoesIndustry.h:44
pi_fungi_one
Definition: PotatoesIndustry.h:60
pi_insecticide
Definition: PotatoesIndustry.h:56
pi_herbi_two
Definition: PotatoesIndustry.h:50
pi_water_two
Definition: PotatoesIndustry.h:58
pi_fungi_three
Definition: PotatoesIndustry.h:62
pi_fungi_five
Definition: PotatoesIndustry.h:64
pi_spring_plough
Definition: PotatoesIndustry.h:43
pi_strigling_two
Definition: PotatoesIndustry.h:53
PotatoesIndustry
Definition: PotatoesIndustry.h:71
pi_harvest
Definition: PotatoesIndustry.h:66
Farm
The base class for all farm types.
Definition: farm.h:767
pi_fungi_two
Definition: PotatoesIndustry.h:61
pi_fa_slurry
Definition: PotatoesIndustry.h:45
pi_water_three
Definition: PotatoesIndustry.h:59
POTATOESIND_BASE
#define POTATOESIND_BASE
Definition: PotatoesIndustry.h:30
pi_fungi_four
Definition: PotatoesIndustry.h:63
pi_strigling_three
Definition: PotatoesIndustry.h:54
pi_water_one
Definition: PotatoesIndustry.h:57
pi_growth_reg
Definition: PotatoesIndustry.h:65
pi_herbi_one
Definition: PotatoesIndustry.h:49
pi_autumn_plough
Definition: PotatoesIndustry.h:42