Merit class for user-defined merit function. More...
#include <brancher-merit.hpp>
Public Types | |
typedef BranchTraits< Var >::Merit | Function |
Corresponding merit function type. More... | |
![]() | |
typedef View | View |
View type. More... | |
typedef View::VarType | Var |
Corresponding variable type. More... | |
typedef double | Val |
Type of merit. More... | |
Public Member Functions | |
MeritFunction (Space &home, const VarBranch< Var > &vb) | |
Constructor for initialization. More... | |
MeritFunction (Space &home, bool shared, MeritFunction &mf) | |
Constructor for cloning. More... | |
double | operator() (const Space &home, View x, int i) |
Return degree as merit for view x at position i. More... | |
bool | notice (void) const |
Whether dispose must always be called (that is, notice is needed) More... | |
void | dispose (Space &home) |
Delete view merit class. More... | |
![]() | |
MeritBase (Space &home, const VarBranch< Var > &vb) | |
Constructor for initialization. More... | |
MeritBase (Space &home, bool share, MeritBase &mb) | |
Constructor for cloning. More... | |
bool | notice (void) const |
Whether dispose must always be called (that is, notice is needed) More... | |
void | dispose (Space &home) |
Delete view merit class. More... | |
Protected Attributes | |
SharedData< Function > | f |
The user-defined merit function. More... | |
Merit class for user-defined merit function.
Definition at line 72 of file brancher-merit.hpp.
typedef BranchTraits<Var>::Merit Gecode::MeritFunction< View >::Function |
Corresponding merit function type.
Definition at line 76 of file brancher-merit.hpp.
|
inline |
Constructor for initialization.
Definition at line 196 of file brancher-merit.hpp.
|
inline |
Constructor for cloning.
Definition at line 203 of file brancher-merit.hpp.
|
inline |
Return degree as merit for view x at position i.
Definition at line 210 of file brancher-merit.hpp.
|
inline |
Whether dispose must always be called (that is, notice is needed)
Definition at line 217 of file brancher-merit.hpp.
|
inline |
Delete view merit class.
Definition at line 222 of file brancher-merit.hpp.
|
protected |
The user-defined merit function.
Definition at line 79 of file brancher-merit.hpp.