[−][src]Enum vampirc_uci::uci::UciMessage
An enumeration type containing representations for all messages supported by the UCI protocol.
Variants
Uci
The uci
engine-bound message.
Debug(bool)
The debug
engine-bound message. Its internal property specifies whether debug mode should be enabled (true
),
or disabled (false
).
IsReady
The isready
engine-bound message.
Register
The register
engine-bound message.
Fields of Register
Position
The position
engine-bound message.
Fields of Position
SetOption
The setoption
engine-bound message.
Fields of SetOption
UciNewGame
The ucinewgame
engine-bound message.
Stop
The stop
engine-bound message.
PonderHit
The ponderhit
engine-bound message.
Quit
The quit
engine-bound message.
Go
The go
engine-bound message.
Fields of Go
time_control: Option<UciTimeControl>
Time-control-related go
parameters (sub-commands).
search_control: Option<UciSearchControl>
Search-related go
parameters (sub-commands).
Id
The id
GUI-bound message.
Fields of Id
UciOk
The uciok
GUI-bound message.
ReadyOk
The readyok
GUI-bound message.
BestMove
The bestmove
GUI-bound message.
Fields of BestMove
CopyProtection(ProtectionState)
The copyprotection
GUI-bound message.
Registration(ProtectionState)
The registration
GUI-bound message.
Option(UciOptionConfig)
The option
GUI-bound message.
Info(Vec<UciInfoAttribute>)
The info
GUI-bound message.
Methods
impl UciMessage
[src]
pub fn register_later() -> UciMessage
[src]
Constructs a register later
UciMessage::Register message.
pub fn register_code(name: &str, code: &str) -> UciMessage
[src]
Constructs a register <code> <name>
UciMessage::Register message.
pub fn go_ponder() -> UciMessage
[src]
Construct a go ponder
UciMessage::Register message.
pub fn go_infinite() -> UciMessage
[src]
Constructs a go infinite
UciMessage::Register message.
pub fn go_movetime(milliseconds: u64) -> UciMessage
[src]
Constructs a go movetime <milliseconds>
UciMessage::Register message, with
milliseconds
as the argument.
pub fn id_name(name: &str) -> UciMessage
[src]
Constructs an id <name>
GUI-bound message.
pub fn id_author(author: &str) -> UciMessage
[src]
Constructs an id <name>
GUI-bound message.
pub fn best_move(best_move: UciMove) -> UciMessage
[src]
Constructs a bestmove
GUI-bound message without the ponder move.
pub fn best_move_with_ponder(best_move: UciMove, ponder: UciMove) -> UciMessage
[src]
Constructs a bestmove
GUI-bound message with the ponder move.
pub fn as_bool(&self) -> Option<bool>
[src]
If this UciMessage
is a UciMessage::SetOption
and the value of that option is a bool
, this method returns
the bool
value, otherwise it returns None
.
pub fn as_i32(&self) -> Option<i32>
[src]
If this UciMessage
is a UciMessage::SetOption
and the value of that option is an integer, this method
returns the i32
value of the integer, otherwise it returns None
.
Trait Implementations
impl Serializable for UciMessage
[src]
fn serialize(&self) -> String
[src]
Serializes the command into a String.
Examples
use vampirc_uci::{UciMessage, Serializable}; println!("{}", UciMessage::Uci.serialize()); // Should print `uci`.
impl PartialEq<UciMessage> for UciMessage
[src]
fn eq(&self, other: &UciMessage) -> bool
[src]
fn ne(&self, other: &UciMessage) -> bool
[src]
impl Clone for UciMessage
[src]
fn clone(&self) -> UciMessage
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Eq for UciMessage
[src]
impl Display for UciMessage
[src]
impl Debug for UciMessage
[src]
impl Hash for UciMessage
[src]
Auto Trait Implementations
impl Send for UciMessage
impl Sync for UciMessage
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,