Gecode::Branching Class Reference
[Programming actors]
Base-class for branchings.
More...
#include <core.hpp>
Protected Member Functions | |
| Branching (Space &home) | |
| Constructor for creation. | |
| Branching (Space &home, bool share, Branching &b) | |
| Constructor for cloning b. | |
Branching | |
| virtual bool | status (const Space &home) const =0 |
| Check status of branching, return true if alternatives left. | |
| virtual const BranchingDesc * | description (Space &home)=0 |
| Return branching description. | |
| virtual ExecStatus | commit (Space &home, const BranchingDesc &d, unsigned int a)=0 |
| Commit for branching description d and alternative a. | |
| unsigned int | id (void) const |
| Return unsigned branching id. | |
Detailed Description
Base-class for branchings.Note that branchings cannot be created inside a propagator (no idea why one would like to do that anyway). If you do that the system will explode in a truly interesting way.
Definition at line 1063 of file core.hpp.
Constructor & Destructor Documentation
| Gecode::Branching::Branching | ( | Space & | home | ) | [inline, protected] |
Member Function Documentation
| virtual bool Gecode::Branching::status | ( | const Space & | home | ) | const [pure virtual] |
Check status of branching, return true if alternatives left.
This method is called when Space::status is called, it determines whether to continue branching with this branching or move on to the (possibly) next branching.
Implemented in BlackHoleBranch, QueenArmies::QueenBranch, Radiotherapy::NestedSearch, SteelMill::SteelMillBranch, Gecode::FunctionBranch, Gecode::ViewBranching< ViewSel >, and Gecode::ViewBranching< ViewSel >.
| virtual const BranchingDesc* Gecode::Branching::description | ( | Space & | home | ) | [pure virtual] |
Return branching description.
Note that this method relies on the fact that it is called immediately after a previous call to status. Moreover, the member function can only be called once.
Implemented in BlackHoleBranch, QueenArmies::QueenBranch, Radiotherapy::NestedSearch, SteelMill::SteelMillBranch, Gecode::Int::Branch::ViewValuesBranching< ViewSel, View >, Gecode::FunctionBranch, and Gecode::ViewValBranching< ViewSel, ValSel >.
| virtual ExecStatus Gecode::Branching::commit | ( | Space & | home, | |
| const BranchingDesc & | d, | |||
| unsigned int | a | |||
| ) | [pure virtual] |
Commit for branching description d and alternative a.
The current branching in the space home performs a commit from the information provided by the branching description d and the alternative a.
Implemented in BlackHoleBranch, QueenArmies::QueenBranch, Radiotherapy::NestedSearch, SteelMill::SteelMillBranch, Gecode::Int::Branch::ViewValuesBranching< ViewSel, View >, Gecode::FunctionBranch, and Gecode::ViewValBranching< ViewSel, ValSel >.
| unsigned int Gecode::Branching::id | ( | void | ) | const [inline] |
The documentation for this class was generated from the following file:
- gecode/kernel/core.hpp (Revision: 8992)
