|
BenBot 1.7.5
A chess engine
|
#include <libchess/uci/Options.hpp>
Public Types | |
| using | Callback = std::function<void()> |
| using | Value = void |
| using | Variant = std::variant<bool, int, string_view> |
Public Member Functions | |
| Action (string name, Callback &&action, string helpString) | |
| auto | get_declaration_string () const -> string override |
| auto | get_default_value_variant () const -> Variant override |
| auto | get_help () const noexcept -> string_view override |
| auto | get_name () const noexcept -> string_view override |
| auto | get_type () const noexcept -> string_view override |
| auto | get_value_variant () const -> Variant override |
| void | handle_setvalue (string_view arguments) override |
| auto | has_value () const noexcept -> bool override |
A triggerable action.
Definition at line 299 of file Options.hpp.
| using chess::uci::Action::Callback = std::function<void()> |
Definition at line 301 of file Options.hpp.
| using chess::uci::Action::Value = void |
Definition at line 300 of file Options.hpp.
|
inherited |
Represents a variant that can hold any of the derived class's value types.
Definition at line 68 of file Options.hpp.
| chess::uci::Action::Action | ( | string | name, |
| Callback && | action, | ||
| string | helpString ) |
Creates an action option.
|
nodiscardoverridevirtual |
Returns the option's declaration string suitable for sending to the GUI. The returned string includes the "option" token.
Implements chess::uci::Option.
|
inlinenodiscardoverridevirtual |
Returns this option's default value, as a variant. Note that if has_value() returns false, you must not call this method!
Implements chess::uci::Option.
Definition at line 310 of file Options.hpp.
|
inlinenodiscardoverridevirtualnoexcept |
Returns the help string for this option.
Implements chess::uci::Option.
Definition at line 318 of file Options.hpp.
|
inlinenodiscardoverridevirtualnoexcept |
Returns this option's name.
Implements chess::uci::Option.
Definition at line 312 of file Options.hpp.
|
inlinenodiscardoverridevirtualnoexcept |
Returns a textual representation of this option's type.
Implements chess::uci::Option.
Definition at line 316 of file Options.hpp.
|
inlinenodiscardoverridevirtual |
Returns this option's current value, as a variant. Note that if has_value() returns false, you must not call this method!
Implements chess::uci::Option.
Definition at line 309 of file Options.hpp.
|
overridevirtual |
Will be called with everything in the "setoption" command after the option name. This is typically not called directly by user code.
Implements chess::uci::Option.
|
inlinenodiscardoverridevirtualnoexcept |
Returns true if this option type has an associated value. False only for Action options.
Reimplemented from chess::uci::Option.
Definition at line 320 of file Options.hpp.