Class RouteEdge - RouteEdge.h, RouteEdge.cc
Definition:
A class used by the class RouteTracks.
A RouteEdge is simply a vertical or horizontal edge used to connect two
MazePoints.
Each edge is assigned a track and edge number as well as a vertical or
horizontal orientation corresponding to its location within the maze.
Additionally, each edge hold the nets which are
routed over it. There is no explicit way of determining which two MazePoints
a route edge connects, but you can implicitly find them by the track number,
edge number and the orientation of the edge. I never implicitly showed
the connection just because I never needed it, though it would be a nice
addition.
Typedefs:
typedef list<Net *> NetList;
typedef NetList::iterator NetListItr;
Included:
#include "Net.h"
#include <list>
bool horizontal
The orientation of this edge.
int trackNum
The track number of this edge.
int edgeNum
The edge number (within the track) of this edge.
int numNets
The number of nets which are routed over this edge.
NetList * netList
A list of the nets which are routed over this edge.

-
RouteEdge()
-
Default constructor.
-
RouteEdge(bool
horiz, int row_or_col, int edge_num)
-
Sets the orientation (horizontal), the track
number trackNum and the edge number edgeNum.
-
~RouteEdge()
-
Deconstructor.
-

-
bool isHorizontal()
-
Returns 'true' if the orientation (horizontal)
of the edge is horizontal.
-
bool isVertical()
-
Returns 'true' if the orientation (horizontal)
of the edge is vertical.
-
int getEdgeNum()
-
Returns the number of the edge (edgeNum) within
the track. NOTE: there can be several edges with the same edge number,
but they should have different edge numbers. This is not meant to uniquely
identify an edge.
-
int getTrackNum()
-
Returns the number of the track (trackNum) of this
edge.
-
int getNumNets()
-
Returns the number of nets which are routed over this edge.
-
NetList * getNetList()
-
Returns a pointer to the list of nets which are routed over this edge.
-
void addNet(Net
* aNet)
-
Adds the specified Net as routed over this edge.
-
void removeNet(Net
* aNet)
-
Removes the specified net as routed over this edge.
-
void resetNumNets()
-
Resets the variable numNets to the size of the net
list netList. This variable should always
be consistent, but this function was created to insure that it is consistent.
-
void print()
-
A debugging function which prints the location of this edge (track num,
edge num, orientation).