UnCoVer (Using Coverability for Verification)
|
This data structure stores a collection of graphs minimal to some given order. More...
#include <MinGraphList.h>
Public Member Functions | |
MinGraphList (basic_types::Order_sp order, analysis::BackwardResultHandler_sp resHandler=nullptr) | |
Generates a new MinGraphList using the given Order for minimization and the given BackwardResultHandler (if given) for storing intermediate results. More... | |
virtual | ~MinGraphList () |
Destroys this MinGraphList. | |
shared_ptr< vector < Hypergraph_sp > > | getGraphs () |
Returns the minimal graphs stores in this MinGraphList as a vector of Hypergraphs. More... | |
bool | addGraph (Hypergraph_sp graph, shared_ptr< vector< Hypergraph_sp >> deletedGraphs=nullptr) |
Adds the given graph to this MinGraphList, if there is no graph already in the list which is smaller of equal to the given graph. More... | |
size_t | addGraphs (vector< Hypergraph_sp > const &graphs) |
Adds the given collection of graphs to this MinGraphList. More... | |
size_t | size () const |
Returns the number of minimal graphs stored in this list. More... | |
bool | contains (IDType graphID) const |
Checks whether a graph with the given ID is stored in this list. More... | |
Private Attributes | |
basic_types::Order_sp | order |
Stores the Order used for minimization. | |
shared_ptr< vector < graphs::Hypergraph_sp > > | graphs |
Stores the minimal graphs. | |
analysis::BackwardResultHandler_sp | resHandler |
Stores the BackwardResultHandler for handling intermediate results. | |
unordered_set< IDType > | idsInList |
Caches all IDs of graphs currently stored in this list. | |
This data structure stores a collection of graphs minimal to some given order.
A graph is only added to this list if there is no graph in the list which is less or equal to the graph. Additionally, after adding a graph all graphs which are now non-minimal are deleted.
MinGraphList | ( | basic_types::Order_sp | order, |
analysis::BackwardResultHandler_sp | resHandler = nullptr |
||
) |
Generates a new MinGraphList using the given Order for minimization and the given BackwardResultHandler (if given) for storing intermediate results.
order | the Order to be used for minimization |
resHandler | the BackwardResultHandler for storing intermediate results (use null if no storing is desired) |
bool addGraph | ( | Hypergraph_sp | graph, |
shared_ptr< vector< Hypergraph_sp >> | deletedGraphs = nullptr |
||
) |
Adds the given graph to this MinGraphList, if there is no graph already in the list which is smaller of equal to the given graph.
After that, the list is minimized.
graph | the graph to be added |
deletedGraphs | if not null, all deleted graphs will be added to this vector |
size_t addGraphs | ( | vector< Hypergraph_sp > const & | graphs | ) |
Adds the given collection of graphs to this MinGraphList.
Every non-minimal graph in the collection is immediately dropped.
graphs | the collection of graphs to be added |
bool contains | ( | IDType | graphID | ) | const |
Checks whether a graph with the given ID is stored in this list.
graphID | the ID to be checked |
shared_ptr< vector< Hypergraph_sp > > getGraphs | ( | ) |
Returns the minimal graphs stores in this MinGraphList as a vector of Hypergraphs.
Modifying the returned vector will invalidate this MinGraphList.
size_t size | ( | ) | const |
Returns the number of minimal graphs stored in this list.