#include <lemon/list_graph.h>
Inherits AlterationNotifier::ObserverBase, and AlterationNotifier::ObserverBase.
Inheritance diagram for ListGraph::Snapshot:
The newly added nodes and edges can be removed using the restore() function.
Snapshots cannot be nested.
Public Member Functions | |
Snapshot () | |
Default constructur. | |
Snapshot (ListGraph &_g) | |
Constructor that immediately makes a snapshot. | |
~Snapshot () | |
void | save (ListGraph &_g) |
Make a snapshot. | |
void | restore () |
Undo the changes until the last snapshot. | |
Protected Member Functions | |
virtual void | build () |
virtual void | clear () |
|
Default constructur. To actually make a snapshot you must call save(). |
|
This constructor immediately makes a snapshot of the graph.
|
|
|
|
Implements AlterationNotifier::ObserverBase. |
|
Implements AlterationNotifier::ObserverBase. |
|
Make a snapshot of the graph. This function can be called more than once. In case of a repeated call, the previous snapshot gets lost.
|
|
Undo the changes until last snapshot created by save().
|