ptype.h

#include "osl/config.h"
#include "osl/player.h"
#include <cassert>
#include <iosfwd>

ptype.hのインクルード依存関係図

このグラフは、どのファイルから直接、間接的にインクルードされているかを示しています。

ソースコードを見る。

ネームスペース

namespace  osl

マクロ定義

#define NEW_PTYPEO(player, ptype)   static_cast<PtypeO>(static_cast<int>(ptype)-(16&static_cast<int>(player)))

列挙型

enum  osl::Ptype {
  osl::PTYPE_EMPTY = 0, osl::PTYPE_EDGE = 1, osl::PPAWN = 2, osl::PLANCE = 3,
  osl::PKNIGHT = 4, osl::PSILVER = 5, osl::PBISHOP = 6, osl::PROOK = 7,
  osl::KING = 8, osl::GOLD = 9, osl::PAWN = 10, osl::LANCE = 11,
  osl::KNIGHT = 12, osl::SILVER = 13, osl::BISHOP = 14, osl::ROOK = 15,
  osl::PTYPE_MIN = 0, osl::PTYPE_BASIC_MIN = KING, osl::PTYPE_PIECE_MIN = 2, osl::PTYPE_MAX = 15
}
 μ4ӥåȤǥɲ [詳細]
enum  osl::PtypeO { osl::PTYPEO_MIN = PTYPE_EMPTY-16, osl::PTYPEO_MAX = 15 }
 Player + Ptype [-15, 15] PtypeO O Owner O [詳細]

関数

std::istream & osl::operator>> (std::istream &is, Ptype &ptype)
std::ostream & osl::operator<< (std::ostream &os, const Ptype ptype)
bool osl::isValid (Ptype ptype)
 intcastƺäptypeϰϤäƤ뤫ɤΥå
bool osl::isPiece (Ptype ptype)
 ptypeEDGEǤʤΥå
bool osl::isBasic (Ptype ptype)
 ptypeܷ(promoteƤʤ)Υå
bool osl::isPromoted (Ptype ptype)
 ptypepromoteηɤΥå
bool osl::canPromote (Ptype ptype)
 ptypepromoteǽʷɤΥå promoteѤߤξfalse֤
Ptype osl::unpromote (Ptype ptype)
 ptypepromoteηλˡpromoteη֤ promoteƤʤλϤΤޤ֤
Ptype osl::promote (Ptype ptype)
 promoteǽptypeФơpromoteη֤ promoteԲĤptypeͿƤϤʤ
bool osl::isMajorBasic (Ptype ptype)
bool osl::isMajor (Ptype ptype)
unsigned int osl::ptypeOIndex (PtypeO ptypeo)
PtypeO osl::newPtypeO (Player player, Ptype ptype)
Ptype osl::getPtype (PtypeO ptypeO)
PtypeO osl::promote (PtypeO ptypeO)
 promoteԲĤptypeͿƤϤʤ
PtypeO osl::promoteWithMask (PtypeO ptypeO, int promoteMask)
 piecepromote뤿Τ promoteMask0x80000 0
PtypeO osl::unpromote (PtypeO ptypeO)
 promoteƤʤptypeͿƤ褤
PtypeO osl::unpromoteWithMask (PtypeO ptypeO, int promoteMask)
 piecepromote뤿Τ promoteMask0x80000 0
bool osl::isValidPtypeO (int ptypeO)
bool osl::isPiece (PtypeO ptypeO)
 EMPTY, EDGEǤϤʤ
Player osl::getOwner (PtypeO ptypeO)
PtypeO osl::captured (PtypeO ptypeO)
 unpromoteȶˡownerȿž롥
bool osl::canPromote (PtypeO ptypeO)
bool osl::isPromoted (PtypeO ptypeO)
 ptypeO promoteѤߤɤ
std::ostream & osl::operator<< (std::ostream &os, const PtypeO ptypeO)

変数

const int osl::PTYPE_SIZE = PTYPE_MAX-PTYPE_MIN+1
const PtypeO osl::PTYPEO_EMPTY = newPtypeO(BLACK,PTYPE_EMPTY)
const PtypeO osl::PTYPEO_EDGE = newPtypeO(WHITE,PTYPE_EDGE)
const int osl::PTYPEO_SIZE = PTYPEO_MAX-PTYPEO_MIN+1


マクロ定義

#define NEW_PTYPEO ( player,
ptype   )     static_cast<PtypeO>(static_cast<int>(ptype)-(16&static_cast<int>(player)))


Thu Oct 8 05:01:13 2009に生成されました。  doxygen 1.5.6