Class to manage callback function for ABS2 QUBO solver.
More...
#include <abs2.hpp>
|
| | Callback () |
| | Constructor for creating a callback object. More...
|
| |
| virtual | ~Callback ()=default |
| | Destructor for deleting a callback object. More...
|
| |
| virtual void | callback (const std::string &event)=0 |
| | Callback function must be defined by user. More...
|
| |
| void | set (const std::string &operation) |
| | Set the operation to the ABS2 Callback. More...
|
| |
| void | set (const std::string &operation, const std::string &operand) |
| | Set the operation and operand to the ABS2 Callback. More...
|
| |
| void | set (const Sol &hint) |
| | Provide a hint solution to the ABS2 solver. More...
|
| |
| const Sol & | get () const |
| | Get the current solution. More...
|
| |
|
| std::shared_ptr< Impl > | pimpl |
| |
Class to manage callback function for ABS2 QUBO solver.
Definition at line 258 of file abs2.hpp.
◆ Callback()
| abs2::Callback::Callback |
( |
| ) |
|
Constructor for creating a callback object.
◆ ~Callback()
| virtual abs2::Callback::~Callback |
( |
| ) |
|
|
virtualdefault |
Destructor for deleting a callback object.
- Note
- Do not delete the callback object.
Reimplemented in qbpp_abs2::Callback.
◆ callback()
| virtual void abs2::Callback::callback |
( |
const std::string & |
event | ) |
|
|
pure virtual |
◆ set() [1/3]
| void abs2::Callback::set |
( |
const std::string & |
operation | ) |
|
Set the operation to the ABS2 Callback.
- Parameters
-
| operation | Operation string |
Set the operation to the ABS2 Callback.
◆ set() [2/3]
| void abs2::Callback::set |
( |
const std::string & |
operation, |
|
|
const std::string & |
operand |
|
) |
| |
Set the operation and operand to the ABS2 Callback.
- Parameters
-
| operation | Operation string |
| operand | Operand string |
Set the operation and operand to the ABS2 Callback.
◆ set() [3/3]
| void abs2::Callback::set |
( |
const Sol & |
hint | ) |
|
Provide a hint solution to the ABS2 solver.
- Parameters
-
Provide a hint solution will be used by the ABS2 solver to improve the solution.
◆ get()
| const Sol& abs2::Callback::get |
( |
| ) |
const |
Get the current solution.
◆ pimpl
| std::shared_ptr<Impl> abs2::Callback::pimpl |
|
private |
The documentation for this class was generated from the following file: