class ABA_NONDUPLPOOL provides an ABA_STANDARDPOOL with the additional feature that the same constraint is at most stored once in the pool. For constraints and variables inserted in this pool the virtual member functions name(), hashKey(), and equal() of the base class ABA_CONVAR have to be defined
#include <nonduplpool.h>
Inheritance diagram for ABA_NONDUPLPOOL< BaseType, CoType >::
|
The destructor.
Before the function insert() tries to insert a constraint/variable in the pool, it checks if the constraint/variable is already contained in the pool. If the constraint/variable cv is contained in the pool, it is deleted.
Determines the number of constraints that have not been inserted into the pool, because an equivalent was already present.
Has to be redefined because the slot has to be removed from the hash table if the constraint/variable can be deleted.
class ABA_NONDUPLPOOL provides an ABA_STANDARDPOOL with the additional feature that the same constraint is at most stored once in the pool. For constraints and variables inserted in this pool the virtual member functions name(), hashKey(), and equal() of the base class ABA_CONVAR have to be defined
Definition at line 52 of file nonduplpool.h.
The constructor for an empty pool.
The destructor.
Before the function insert() tries to insert a constraint/variable in the pool, it checks if the constraint/variable is already contained in the pool. If the constraint/variable cv is contained in the pool, it is deleted.
A pointer to the pool slot where the item has been inserted, or a pointer to the pool slot if the item is already contained in the pool, or 0 if the insertion failed.
Reimplemented from ABA_STANDARDPOOL< BaseType, CoType >.
Checks if a constraint/variables is already contained in the pool.
A pointer to the pool slot storing a constraint/variable that is equivalent to cv according to the function ABA_CONVAR::equal(). If there is no such constraint/variable 0 is returned.
Enlarges the pool to store.
To avoid fatal errors we do not allow decreasing the size of the pool. This function redefines the virtual function of the base class ABA_STANDARDPOOL because we have to reallocate the hash table.
Reimplemented from ABA_STANDARDPOOL< BaseType, CoType >.
Determines the number of constraints that have not been inserted into the pool, because an equivalent was already present.
Also the number of collisions in the hash table is computed. If this number is high, it might indicate that your hash function is not chosen very well.
Has to be redefined because the slot has to be removed from the hash table if the constraint/variable can be deleted.
0 If the constraint/variable could be deleted.
1 otherwise.
Reimplemented from ABA_POOL< BaseType, CoType >.
Has to be redefined because the pool slot has to be removed from the hash table.
Reimplemented from ABA_POOL< BaseType, CoType >.
Definition at line 142 of file nonduplpool.h.
Definition at line 143 of file nonduplpool.h.
The documentation for this class was generated from the following file: