-
Notifications
You must be signed in to change notification settings - Fork 0
/
animal.h
187 lines (137 loc) · 4.24 KB
/
animal.h
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
#ifndef ANIMAL_H
#define ANIMAL_H
#include <iostream>
using namespace std;
class Animal{
//friend class Array<Animal>;
public:
Animal(string,string);
virtual ~Animal();
/*this fucntion setsn the basic information about the animals such as name apsecies and gender*/
void setBasicInfo(string,string, string,string,string,string);
bool operator==(Animal*);
/*getters overwritten for inheritance purposes*/
/*Mammal class*/
virtual string getMammalHairLength();
virtual string getMammalHairColour();
/*Mammal and Amphibian class */
virtual string getBuild();
/*Amphibian, reptile, fish class*/
virtual string getLength();
virtual string getBodyPattern();
/*Fish class*/
virtual string getFinnsSize();
/*Bird class*/
virtual string getWingSpan();
virtual string getBeakLength();
virtual string getBeakColour();
virtual string getScaleType();
/*Reptile class*/
/*setters overwritten for inheritance purposes*/
/*this function will be overwrittem in all of the classes*/
virtual void setPhysCharacteristics(string,string,string);
/*Mammal class*/
virtual void setMammalHairLength(string);
virtual void setMammalHairColour(string);
/*Mammal and Amphibian class*/
virtual void setBuild(string);
/*Amphibian, reptile, fish class*/
virtual void setLength(string);
virtual void setBodyPattern(string);
/*Fish class*/
virtual void setFinnsSize(string);
/*Bird class*/
virtual void setWingSpan(string);
virtual void setBeakLength(string);
virtual void setBeakColour(string);
/*Reptile class*/
virtual void setScaleType(string);
virtual void setNonPhysicalAttributes(string,string,string,string,string,string,string,string,string,string,string,string);
/*getters for all attributes physiscal attributes*/
string getName();
string getSpecies();
string getAge();
string getGender();
string getColour();
string getHeight();
string getWeight();
string getType();
/*getters for all attributes non-physiscal attributes*/
string getActiveness();
string getPlayfulness();
string getIndividualism();
string getAffectionism();
string getIntelligence();
string getDiscipline();
string getAssertiveness();
string getSpaciousness();
string getEnergetic();
string getDiurnalNocturnal();
string getHabitatPreference();
string getAppetite();
/*setters for all attributes physiscal attributes*/
void setName(string);
void setSpecies(string);
void setAge(string);
void setGender(string);
void setColour(string);
void setHeight(string);
void setWeight(string);
void setType(string);
/*setters for all attributes non-physiscal attributes*/
void setActiveness(string);
void setPlayfulness(string);
void setIndividualism(string);
void setAffectionism(string);
void setIntelligence(string);
void setDiscipline(string);
void setAssertiveness(string);
void setHabitatPreference(string);
void setDiurnalNocturnal(string);
void setEnergetic(string);
void setAppetite(string);
void setSpaciousness(string);
void setEnergy(string);
void setEdited(bool);
void setAnimalId(int);
void incramentID(int);
int getAnimalID();
//Helper setter functions
void setNewAnimal(bool);
void setID(int);
bool getEdited();
//Helper getter functions
bool getNewAnimal();
/*for testing purposes*/
virtual void print();
virtual void printPhys();
protected:
/*Attributes set in constructor*/
string name;
string species;
/*Attributes set in setBasicInfo*/
string age;
string gender;
string colour;
/* Attributes set in setPhysCharacteristics */
string height;
string weight;
string typeOfAnimal;
/*non -physical attributes inherited by all classes*/
string activeness;
string playfulness;
string individualism;
string affectionism;
string intelligence;
string discipline;
string assertiveness;
string energetic;
string diurnalNocturnal;
string spaciousness;
string appetite;
string habitatPref;
int ID;
bool edited;
bool isNewAnimal;
};
#endif