gnushogi で使われるフォーマット. More...
Classes | |
class | ParseError |
Functions | |
const Move | strToMove (const std::string &, const state::SimpleState &) |
const Square | strToPos (const std::string &) |
Ptype | charToPtype (char) |
const std::string | show (Move) |
const std::string | show (Square) |
char | show (Ptype) |
const std::string | showXP (Move) |
decorate capture by 'x', promote by '+', and unpromote by '=' More... | |
gnushogi で使われるフォーマット.
何種類かある.
osl::Ptype osl::record::psn::charToPtype | ( | char | c) |
Definition at line 124 of file psn.cc.
References osl::BISHOP, osl::GOLD, osl::KING, osl::KNIGHT, osl::LANCE, osl::PAWN, osl::PTYPE_EMPTY, osl::ROOK, and osl::SILVER.
Referenced by osl::record::usi::charToPtypeO().
const std::string osl::record::psn::show | ( | Move | m) |
Definition at line 37 of file psn.cc.
References osl::Move::from(), osl::Square::isPieceStand(), osl::Move::promoteMask(), osl::Move::ptype(), result, osl::record::csa::show(), and osl::Move::to().
Referenced by osl::game_playing::GnuShogiClient::processComputerMove(), and osl::game_playing::GnuShogiClient::readAndProcessCommand().
const std::string osl::record::psn::show | ( | Square | pos) |
Definition at line 7 of file psn.cc.
References result, osl::Square::x(), and osl::Square::y().
char osl::record::psn::show | ( | Ptype | ptype) |
Definition at line 18 of file psn.cc.
References osl::BISHOP, osl::GOLD, osl::KING, osl::KNIGHT, osl::LANCE, osl::PAWN, osl::ROOK, and osl::SILVER.
const std::string osl::record::psn::showXP | ( | Move | m) |
decorate capture by 'x', promote by '+', and unpromote by '='
Definition at line 56 of file psn.cc.
References osl::canPromote(), osl::Square::canPromote(), osl::Move::capturePtype(), osl::Move::from(), osl::Move::isInvalid(), osl::Move::isPass(), osl::Square::isPieceStand(), osl::Move::isPromotion(), osl::Move::player(), osl::Move::ptype(), osl::PTYPE_EMPTY, result, osl::record::csa::show(), and osl::Move::to().
const Move osl::record::psn::strToMove | ( | const std::string & | , |
const state::SimpleState & | |||
) |
Referenced by osl::game_playing::GnuShogiClient::readAndProcessCommand().
const osl::Square osl::record::psn::strToPos | ( | const std::string & | str) |