Base-class for brancher for integer and Boolean views. More...
#include <branch.hh>
Public Member Functions | |
virtual bool | status (const Space &home) const |
Check status of brancher, return true if alternatives left. | |
virtual const Choice * | choice (Space &home)=0 |
Return choice. | |
virtual const Choice * | choice (const Space &home, Archive &e) |
Return choice. | |
virtual ExecStatus | commit (Space &home, const Choice &c, unsigned int b) |
Perform commit for choice c and alternative b. | |
virtual NGL * | ngl (Space &home, const Choice &c, unsigned int b) const |
Create no-good literal for choice c and alternative b. | |
virtual void | print (const Space &home, const Choice &c, unsigned int b, std::ostream &o) const |
Print branch for choice c and alternative b. | |
virtual size_t | dispose (Space &home) |
Delete brancher and return its size. | |
![]() | |
unsigned int | id (void) const |
Return brancher id. | |
BrancherGroup | group (void) const |
Return group brancher belongs to. | |
void | group (BrancherGroup g) |
Add brancher to group g. | |
![]() | |
virtual Actor * | copy (Space &home)=0 |
Create copy. | |
virtual | ~Actor (void) |
To avoid warnings. | |
Protected Member Functions | |
IntBoolBrancherBase (Space &home, IntBoolBrancherBase &b) | |
Constructor for cloning b. | |
IntBoolBrancherBase (Home home, ViewArray< Int::IntView > x, ViewArray< Int::BoolView > y, ValSelCommitBase< Int::IntView, int > *xvsc, ValSelCommitBase< Int::BoolView, int > *yvsc) | |
Constructor for creation. | |
![]() | |
Brancher (Home home) | |
Constructor for creation. | |
Brancher (Space &home, Brancher &b) | |
Constructor for cloning b. | |
Protected Attributes | |
ViewArray< Int::IntView > | x |
Integer views to branch on. | |
ViewArray< Int::BoolView > | y |
Boolean views to branch on. | |
int | start |
Unassigned views start here (might be in x or y) | |
ValSelCommitBase< Int::IntView, int > * | xvsc |
Integer value selection and commit object. | |
ValSelCommitBase< Int::BoolView, int > * | yvsc |
Boolean value selection and commit object. | |
Additional Inherited Members | |
![]() | |
static void * | operator new (size_t s, Space &home) |
Allocate memory from space. | |
static void | operator delete (void *p, Space &home) |
No-op for exceptions. | |
static void * | operator new (size_t s) |
Not used. | |
static void | operator delete (void *p) |
Not used. | |
|
inlineprotected |
Constructor for cloning b.
Definition at line 315 of file branch.hpp.
|
inlineprotected |
Constructor for creation.
Definition at line 304 of file branch.hpp.
|
virtual |
Check status of brancher, return true if alternatives left.
Implements Gecode::Brancher.
Definition at line 48 of file branch.cpp.
Return choice.
Implements Gecode::Brancher.
Implemented in Gecode::FlatZinc::IntBoolBrancher< Merit >.
|
virtual |
Perform commit for choice c and alternative b.
Implements Gecode::Brancher.
Definition at line 66 of file branch.cpp.
|
virtual |
Create no-good literal for choice c and alternative b.
Reimplemented from Gecode::Brancher.
Definition at line 82 of file branch.cpp.
|
virtual |
Print branch for choice c and alternative b.
Reimplemented from Gecode::Brancher.
Definition at line 96 of file branch.cpp.
|
inlinevirtual |
Delete brancher and return its size.
Reimplemented from Gecode::Actor.
Reimplemented in Gecode::FlatZinc::IntBoolBrancher< Merit >.
Definition at line 324 of file branch.hpp.
|
protected |
|
protected |
|
mutableprotected |
|
protected |
|
protected |