Observer interface for search progress reporting. More...
#include <search.hpp>
Public Types | |
| typedef std::shared_ptr< SUBSET > | PSubset |
| shared pointer to a feature subset (not used by the interface itself; kept for observer implementations' convenience) | |
Public Member Functions | |
| virtual void | on_progress (const std::string &msg) |
| one pre-formatted progress message | |
| virtual void | on_solution (const RETURNTYPE value, const SUBSET &sub, const std::string &msg) |
| a new (sub-)solution has been reached (msg = its pre-formatted text form); copy sub if kept beyond the call | |
Observer interface for search progress reporting.
Attach via Search::set_observer() to take over delivery of search progress: on_progress() receives each pre-formatted progress message, on_solution() additionally fires whenever a search announces a new (sub-)solution. With no observer attached the search prints the same messages as syncout text to its os stream. A default-constructed Search_Observer swallows everything (quiet mode).
|
inlinevirtual |
one pre-formatted progress message
Reimplemented in fst4_cli::Observer_Curve.