![]() | ||||||
#include <Allocatn.h>
Collaboration diagram for AreaIterator:

An iterator which iterates through the area assignments for a specified resource. Conceptually, returns a pair (A,T) of (area, duration assigned there), thus "area iterator".
Like the other iterators, it uses accessor functions defined in Allocatn.h and implemented in each allocation class.
Author : Michael Eldridge
Public Member Functions | |
| AreaIterator (const Allocation &p_allocation, const int p_resource_num) | |
| Create an iterator over the areas for that resource. | |
| ~AreaIterator () | |
| Destructor: clean up memory allocated in "current". | |
| void | operator++ (void) |
| Increments the iterator to the next area for this resource. | |
| AreaAssignment | operator * (void) const |
| Returns the object pointed to by this iterator. | |
| bool | atEnd (void) const |
| Checks to see whether the iterator is at the end of the list. | |
| int | getResource (void) const |
Protected Attributes | |
| const Allocation & | myAllocation |
| The allocation being iterated over. | |
| AreaAssignment * | current |
| The current area + time pair for this resource. | |
| const int | myResource |
| The resource for which we're reading assignments. | |
|
||||||||||||
|
Create an iterator over the areas for that resource. Constructor that takes an allocation (could be any sub type) and a resource number and creates an iterator over all areas that have that resource allocated to them, returning AreaAssignments. It begins with the first area to which that resource has been assigned, as implemented by the specific allocation type being called. |
|
|
Destructor: clean up memory allocated in "current". Author: Charles Twardy 18apr03, for bug spotted by GT. |
|
|
Checks to see whether the iterator is at the end of the list. Author : Michael Eldridge |
|
|
Returns the object pointed to by this iterator. Author : Andre Oboler (ASO) |
|
|
Increments the iterator to the next area for this resource. Author : Michael Eldridge Rewritten: Andre Oboler (ASO) |
|
|
The resource for which we're reading assignments. This value may not change |
| (SARBayes) | Main | Related Pages | Class List | Hierarchy | Methods | Files |
|---|