Gadget
migrationareaptrvector.h
Go to the documentation of this file.
1 #ifndef migrationareaptrvector_h
2 #define migrationareaptrvector_h
3 
4 class MigrationArea;
5 
11 public:
15  MigrationAreaPtrVector() { size = 0; v = 0; };
30  void resize(MigrationArea* value);
36  void Delete(int pos);
41  int Size() const { return size; };
47  MigrationArea*& operator [] (int pos) { return v[pos]; };
53  MigrationArea* const& operator [] (int pos) const { return v[pos]; };
54 protected:
62  int size;
63 };
64 
65 #endif
This class implements a dynamic vector of MigrationArea values.
Definition: migrationareaptrvector.h:10
MigrationArea *& operator[](int pos)
This will return the value of an element of the vector.
Definition: migrationareaptrvector.h:47
int size
This is the size of the vector.
Definition: migrationareaptrvector.h:62
~MigrationAreaPtrVector()
This is the MigrationAreaPtrVector destructor.
Definition: migrationareaptrvector.cc:15
void resize(MigrationArea *value)
This will add one new entry to the vector.
Definition: migrationareaptrvector.cc:22
int Size() const
This will return the size of the vector.
Definition: migrationareaptrvector.h:41
MigrationArea ** v
This is the vector of MigrationArea values.
Definition: migrationareaptrvector.h:53
MigrationAreaPtrVector()
This is the default MigrationAreaPtrVector constructor.
Definition: migrationareaptrvector.h:15
void Delete(int pos)
This will delete an entry from the vector.
Definition: migrationareaptrvector.cc:37
This is the class used to store details of the areas used when calculating the migration within the m...
Definition: migrationarea.h:12