|
Open Graph Drawing Framework |
v. 2023.09 (Elderberry)
|
|
|
Go to the documentation of this file.
39 template<
class BaseType,
class CoType>
class PoolSlot;
42 template<
class BaseType,
class CoType>
45 template<
class BaseType,
class CoType>
61 template <
class BaseType,
class CoType>
122 Logger::ifout() <<
"Active::operator[] : no active item in slot " << i <<
".\n";
138 Logger::ifout() <<
"Active::operator[] : no active item in slot " << i <<
".\n";
An array that keeps track of the number of inserted elements; also usable as an efficient stack.
Implements the sets of active constraints and variables which are associated with each subproblem.
Stores a pointer to a pool slot with version number.
int max() const
Returns the maximum number of storable active items (without reallocation).
void realloc(int newSize)
Changes the maximum number of active items which can be stored.
const PoolSlotRef< BaseType, CoType > * poolSlotRef(int i) const
Returns the i-th entry in the Array active.
std::ostream & operator<<(std::ostream &out, const Active< BaseType, CoType > &rhs)
void incrementRedundantAge(int i)
Increments the number ofiterations the item i is already redundant by 1.
Master * master_
A pointer to corresponding master of the optimization.
#define OGDF_NEW_DELETE
Makes the class use OGDF's memory allocator.
const BaseType * operator[](int i) const
Access to the i-th active item.
Exception thrown when an algorithm realizes an internal bug that prevents it from continuing.
int number() const
Returns the current number of active items.
Base class of all other classes of ABACUS.
The parameterized class Array implements dynamic arrays of type E.
BaseType * operator[](int i)
Access to the i-th active item.
void resetRedundantAge(int i)
Sets the number of iterations item i is redundant to 0.
void insert(PoolSlot< BaseType, CoType > *ps)
Adds a constraint/variable to the active items set.
void remove(ArrayBuffer< int > &del)
Removes items from the list of active items.
const Active< BaseType, CoType > & operator=(const Active< BaseType, CoType > &rhs)
#define OGDF_THROW_PARAM(CLASS, PARAM)
Replacement for throw.
Active(Master *master, int max)
Creates an empty set of active items.
static std::ostream & ifout()
stream for forced output (global; used by internal libraries, e.g. Abacus)
Stores constraints and variables.
Array< PoolSlotRef< BaseType, CoType > * > active_
The array storing references to the pool slots of the active items.
int n_
The number of active items.
Array< int > redundantAge_
The number of iterations a constraint is already redundant.
PoolSlotRef< BaseType, CoType > * poolSlotRef(int i)
Returns the i-th entry in the Array active.
int redundantAge(int i) const
Returns the number of iterations a constraint/variable is already redundant.
The master of the optimization.