40 #ifndef __GECODE_INT_VIEW_VAL_GRAPH_HH__ 41 #define __GECODE_INT_VIEW_VAL_GRAPH_HH__ 49 namespace Gecode {
namespace Int {
namespace ViewValGraph {
66 void init(T* p1, T* p2);
104 bool empty(
void)
const;
108 template<
class View>
class Edge;
125 unsigned int low,
min, comp;
134 static void*
operator new(size_t,
Space&);
136 static void operator delete(
void*, size_t);
138 static void operator delete(
void*,
Space&);
196 bool fake(
void)
const;
198 View view(
void)
const;
202 bool changed(
void)
const;
204 bool matched(
void)
const;
249 static void*
operator new(size_t,
Space&);
251 static void operator delete(
void*, size_t);
253 static void operator delete(
void*,
Space&);
273 bool operator ()(
void)
const;
276 void operator ++(
void);
294 namespace Gecode {
namespace Int {
namespace ViewValGraph {
317 void scc(
Space& home);
322 operator bool(
void)
const;
Bidirectional links for edges and anchors in nodes of view-value graph.
bool marked(void *p)
Check whether p is marked.
ViewNode< View > ** view
Array of view nodes.
void * mark(void *p)
Return marked pointer for unmarked pointer p.
Edges in view-value graph.
int n_view
Number of view nodes.
int n_val
Number of value nodes.
const int _val
The value of the node.
Support::StaticStack< ViewNode< View > *, Region > ViewNodeStack
Stack used during matching.
int p
Number of positive literals for node type.
int n
Number of negative literals for node type.
unsigned int _size
The size of the view after last change.
View nodes in view-value graph.
View _view
The node's view.
T * ptr(T *p) const
Return the other pointer when p is given.
Edge< View > * _next_edge
Next edge in chain of value edges.
Edge< View > * _matching
The matching edge.
Class for combining two pointers with a flag.
int is_set(void) const
Check whether flag is set.
View-value graph base class.
Iterates the values to be pruned from a view node.
Edge< View > * _val_edges
The first value edge.
Edge< View > * e
Current value edge.
unsigned int count
Marking counter.
CombPtrFlag< Node< View > > sd
Combine source and destination node and flag.
Value nodes in view-value graph.
Stack with fixed number of elements.
ValNode< View > * val
Array of value nodes.
Post propagator for SetVar x
Gecode toplevel namespace
void init(T *p1, T *p2)
Initialize with pointer p1 and p2.
Edge< View > * iter
Next edge for computing strongly connected components.
ViewNode< View > * x
View node.
void unset(void)
Clear flag.
ExecStatus purge(Space &home, Propagator &p, TaskArray< OptTask > &t)
Purge optional tasks that are excluded and possibly rewrite propagator.
Base-class for nodes (both view and value nodes)
CombPtrFlag(T *p1, T *p2)
Initialize with pointer p1 and p2.
ValNode< View > * _next_val
The next value node.