Biorithm
1.1
|
An abstract class to keep track of updates to a graph. The design is to encapsulate each type of update in its own sub-class. An example of an update is the addition or deletion of a single node or edge. The key member function is reverse(), which allows the update to be reversed on its argument. ! More...
#include <graph.C>
Public Member Functions | |
MyAbstractGraphModification () | |
virtual | ~MyAbstractGraphModification () |
Destructor. | |
virtual MyAbstractGraphModification * | clone ()=0 |
Clone yourself. | |
virtual bool | reverse (MyGraph &graph)=0 |
An abstract class to keep track of updates to a graph. The design is to encapsulate each type of update in its own sub-class. An example of an update is the addition or deletion of a single node or edge. The key member function is reverse(), which allows the update to be reversed on its argument. !
Constructor. Each sub-class will add its own sub-class specific constructors.
virtual bool MyAbstractGraphModification::reverse | ( | MyGraph & | graph | ) | [pure virtual] |
Reverse the effect of the modification on graph and return true if the reversal succeeded.
Implemented in MyGraphNodeInsertion, MyGraphNodeDeletion, MyGraphEdgeInsertion, and MyGraphEdgeDeletion.