1 : |
agomez |
1 |
#ifndef migrationarea_h
|
2 : |
|
|
#define migrationarea_h
|
3 : |
|
|
|
4 : |
|
|
#include "rectangleptrvector.h" |
5 : |
|
|
#include "commentstream.h" |
6 : |
|
|
#include "gadget.h" |
7 : |
|
|
|
8 : |
|
|
/**
|
9 : |
|
|
* \class MigrationArea
|
10 : |
|
|
* \brief This is the class used to store details of the areas used when calculating the migration within the model
|
11 : |
|
|
*/
|
12 : |
|
|
class MigrationArea {
|
13 : |
|
|
public:
|
14 : |
|
|
/**
|
15 : |
|
|
* \brief This is the MigrationArea constructor
|
16 : |
|
|
* \param infile is the CommentStream to read the migration area parameters from
|
17 : |
|
|
* \param name is the name of the migration area
|
18 : |
|
|
* \param id is the internal identifer of the migration area
|
19 : |
|
|
*/
|
20 : |
|
|
MigrationArea(CommentStream& infile, char* name, int id);
|
21 : |
|
|
/**
|
22 : |
|
|
* \brief This is the default MigrationArea destructor
|
23 : |
|
|
*/
|
24 : |
|
|
~MigrationArea();
|
25 : |
|
|
/**
|
26 : |
|
|
* \brief This will return the size of the migration area
|
27 : |
|
|
* \return areaSize
|
28 : |
|
|
*/
|
29 : |
|
|
double getArea() { return areaSize; };
|
30 : |
|
|
/**
|
31 : |
|
|
* \brief This will return the internal identifier of the migration area
|
32 : |
|
|
* \return areaid
|
33 : |
|
|
*/
|
34 : |
|
|
int getAreaID() { return areaid; };
|
35 : |
|
|
/**
|
36 : |
|
|
* \brief This will return the number of rectangles that make up the the migration area
|
37 : |
|
|
* \return number of rectangles
|
38 : |
|
|
*/
|
39 : |
|
|
int getNumRectangles() { return rectangles.Size(); };
|
40 : |
|
|
/**
|
41 : |
|
|
* \brief This will return the RectanglePtrVector of rectangles that make up the the migration area
|
42 : |
|
|
* \return rectangles, a RectanglePtrVector of the rectangles that make up the migration area
|
43 : |
|
|
*/
|
44 : |
|
|
RectanglePtrVector& getRectangles() { return rectangles; };
|
45 : |
|
|
private:
|
46 : |
|
|
/**
|
47 : |
|
|
* \brief This is the name of the migration area
|
48 : |
|
|
*/
|
49 : |
|
|
char* areaName;
|
50 : |
|
|
/**
|
51 : |
|
|
* \brief This is the internal identifier for the migration area
|
52 : |
|
|
*/
|
53 : |
|
|
int areaid;
|
54 : |
|
|
/**
|
55 : |
|
|
* \brief This is the calculated size of the area of the migration area
|
56 : |
|
|
*/
|
57 : |
|
|
double areaSize;
|
58 : |
|
|
/**
|
59 : |
|
|
* \brief This is the RectanglePtrVector of the rectangles that make up the the migration area
|
60 : |
|
|
*/
|
61 : |
|
|
RectanglePtrVector rectangles;
|
62 : |
|
|
};
|
63 : |
|
|
|
64 : |
|
|
#endif
|