C++ Reference
C++ Reference: Routing
LocalSearchFilterManager
Detailed Description
Filter manager: when a move is made, filters are executed to decide whether the solution is feasible and compute parts of the new cost.
This class schedules filter execution and composes costs as a sum.
Definition at line 1763 of file constraint_solveri.h.
Classes | |
struct | FilterEvent |
Public Types | |
enum | FilterEventType { kAccept , kRelax } |
Public Member Functions | |
std::string | DebugString () const override |
LocalSearchFilterManager (std::vector< FilterEvent > filter_events) | |
LocalSearchFilterManager (std::vector< LocalSearchFilter * > filters) | |
void | Revert () |
bool | Accept (LocalSearchMonitor *const monitor, const Assignment *delta, const Assignment *deltadelta, int64 objective_min, int64 objective_max) |
Returns true iff all filters return true, and the sum of their accepted objectives is between objective_min and objective_max. More... | |
void | Synchronize (const Assignment *assignment, const Assignment *delta) |
Synchronizes all filters to assignment. More... | |
int64 | GetSynchronizedObjectiveValue () const |
int64 | GetAcceptedObjectiveValue () const |
Member Enumeration Documentation
◆ FilterEventType
enum FilterEventType |
Enumerator | |
---|---|
kAccept | |
kRelax |
Definition at line 1767 of file constraint_solveri.h.
Constructor & Destructor Documentation
◆ LocalSearchFilterManager() [1/2]
|
explicit |
◆ LocalSearchFilterManager() [2/2]
|
explicit |
Member Function Documentation
◆ Accept()
bool Accept | ( | LocalSearchMonitor *const | monitor, |
const Assignment * | delta, | ||
const Assignment * | deltadelta, | ||
int64 | objective_min, | ||
int64 | objective_max | ||
) |
Returns true iff all filters return true, and the sum of their accepted objectives is between objective_min and objective_max.
The monitor has its Begin/EndFiltering events triggered.
◆ DebugString()
|
inlineoverridevirtual |
Reimplemented from BaseObject.
Definition at line 1773 of file constraint_solveri.h.
◆ GetAcceptedObjectiveValue()
|
inline |
Definition at line 1795 of file constraint_solveri.h.
◆ GetSynchronizedObjectiveValue()
|
inline |
Definition at line 1794 of file constraint_solveri.h.
◆ Revert()
void Revert | ( | ) |
◆ Synchronize()
void Synchronize | ( | const Assignment * | assignment, |
const Assignment * | delta | ||
) |
Synchronizes all filters to assignment.
The documentation for this class was generated from the following file: