#include <EdgeIterator.h>
Public Types | |
enum | ITERATIONMODE { SAMPLEOCCURENCE, SAMPLEVALUE } |
Public Member Functions | |
EdgeIterator (void) | |
EdgeIterator (Vertex *v, ITERATIONMODE m=SAMPLEOCCURENCE) | |
EdgeIterator (const EdgeIterator &eit) | |
~EdgeIterator (void) | |
const Edge * | operator * (void) const |
void | operator++ (void) |
void | reset (Vertex *v, ITERATIONMODE m=SAMPLEOCCURENCE) |
void | reset (ITERATIONMODE m=SAMPLEOCCURENCE) |
bool | isFinished (void) const |
VertexLabel | getPartnerVertexLabel (void) const |
void | print (unsigned short spc=0) const |
Static Public Member Functions | |
UWORD32 | getMaxNumEdges (void) |
void | setMaxNumEdges (UWORD32 mne) |
Private Member Functions | |
void | findNextEdge (void) |
bool | isDestSampleValueOK (const SampleValue *sv) |
Private Attributes | |
Edge | CurrentEdge |
the current edge (is returned by operator*) | |
ITERATIONMODE | Mode |
mode of iteration | |
unsigned long * | SVALIndices |
contains (for every sample value) an index to the current opposite neighbour | |
UWORD32 | EdgeIndex |
the index/number of the edge that is currently returned by operator* | |
bool | Finished |
is true iff there are no more edges for this source vertex | |
std::list< SampleOccurence >::const_iterator | SampleOccurenceIt |
Static Private Attributes | |
UWORD32 | MaxNumEdges = UWORD32_MAX |
the maximum number of edges the EdgeIterator should iterate through |
EdgeIterator uses an SampleOccurence::const_iterator to store information about the current edge. Graph::(un)markDeletedSampleOccurence can invalidate such iterators. It is therefore not a good idea to use EdgeIterators at the same time as the Graph::(un)markDeletedSampleOccurence functionality.
NOTE: EdgeIterator relies on the Globals object pointed to by the Globs pointer. This means that it must be set correctly before using any method of an EdgeIterator object.
|
|
|
the default contructor - does not create a valid object |
|
|
|
the copy constructor |
|
|
|
find the shortest edge, starting the search at SVOppNeighsIndices[0...k] set the private variables accordingly is only called to find a new destination sample value, i.e. if one of the SVOppNeighsIndices[i] is changed |
|
|
|
get the label of the partner vertex
|
|
|
|
|
|
get the current edge
|
|
set this iterator to next edge |
|
|
|
reset this iterator to first (shortest) edge |
|
set this iterator to first (shortest) edge of vertex v
|
|
|
|
|
|
|
|
|
|
|
|
|
|
contains the iterator pointing to the sample occurence that constitutes the edge together with SourceVertex/SourceSamleValueIndex |
|
|