Belofte  version 2.1.5
A promising chess program using the UCI or Winboard interface
bBasicMove Class Reference

move More...

Public Member Functions

 bBasicMove (move_t const &mt)
 
 bBasicMove (basicmove_t const &bm)
 
 bBasicMove (case_t cf, case_t ct)
 
virtual ~bBasicMove ()
 
 bBasicMove (bBasicMove const &)=default
 
bBasicMoveoperator= (bBasicMove const &)=default
 
 bBasicMove (bBasicMove &&)=default
 
bBasicMoveoperator= (bBasicMove &&)=default
 
 operator std::string () const
 
MEMBER_CONSTEXPR case_t from () const
 
MEMBER_CONSTEXPR case_t to () const
 
rank_t fromrank () const
 
column_t fromcolumn () const
 
rank_t torank () const
 
column_t tocolumn () const
 
basicmove_t getBasicMoveT () const
 
MEMBER_CONSTEXPR move_t getMoveT () const
 
MEMBER_CONSTEXPR ppiece_t getPromotion () const
 
bool isPromotion () const
 
void setPromotion (ppiece_t const p)
 
bool isCapture () const
 
void setCapture ()
 
bool isPawnMove () const
 
bool isCastleMove () const
 
void setCastleMove (uint16_t f)
 
bool isLongCastleMove () const
 
bool isCheck () const
 
void setCheck ()
 
bool isMate () const
 
void setMate ()
 
bool isEPPossible () const
 
void setEPPossible ()
 
bool isEPMove () const
 
void setEPMove ()
 
void setGameEnd (const moveflags_t e)
 
bool getGameEnd () const
 

Protected Attributes

basicmove_t m_bmove = 0
 
moveflags_t m_movef = 0
 

Friends

std::ostream & operator<< (std::ostream &os, bBasicMove const &m)
 

Detailed Description

move

Definition at line 91 of file move.h.

Constructor & Destructor Documentation

◆ bBasicMove() [1/5]

bBasicMove::bBasicMove ( move_t const &  mt)
explicit

Definition at line 81 of file move.cpp.

◆ bBasicMove() [2/5]

bBasicMove::bBasicMove ( basicmove_t const &  bm)
explicit

Definition at line 87 of file move.cpp.

◆ bBasicMove() [3/5]

bBasicMove::bBasicMove ( case_t  cf,
case_t  ct 
)
explicit

Definition at line 92 of file move.cpp.

◆ ~bBasicMove()

bBasicMove::~bBasicMove ( )
virtual

Definition at line 98 of file move.cpp.

◆ bBasicMove() [4/5]

bBasicMove::bBasicMove ( bBasicMove const &  )
default

◆ bBasicMove() [5/5]

bBasicMove::bBasicMove ( bBasicMove &&  )
default

Member Function Documentation

◆ operator=() [1/2]

bBasicMove& bBasicMove::operator= ( bBasicMove const &  )
default

◆ operator=() [2/2]

bBasicMove& bBasicMove::operator= ( bBasicMove &&  )
default

◆ operator std::string()

bBasicMove::operator std::string ( ) const

Definition at line 102 of file move.cpp.

◆ from()

MEMBER_CONSTEXPR case_t bBasicMove::from ( ) const
inline

Definition at line 109 of file move.h.

Referenced by fromcolumn(), and fromrank().

+ Here is the caller graph for this function:

◆ to()

MEMBER_CONSTEXPR case_t bBasicMove::to ( ) const
inline

Definition at line 113 of file move.h.

Referenced by tocolumn(), and torank().

+ Here is the caller graph for this function:

◆ fromrank()

rank_t bBasicMove::fromrank ( ) const
inline

Definition at line 117 of file move.h.

+ Here is the call graph for this function:

◆ fromcolumn()

column_t bBasicMove::fromcolumn ( ) const
inline

Definition at line 118 of file move.h.

+ Here is the call graph for this function:

◆ torank()

rank_t bBasicMove::torank ( ) const
inline

Definition at line 119 of file move.h.

+ Here is the call graph for this function:

◆ tocolumn()

column_t bBasicMove::tocolumn ( ) const
inline

Definition at line 120 of file move.h.

+ Here is the call graph for this function:

◆ getBasicMoveT()

basicmove_t bBasicMove::getBasicMoveT ( ) const
inline

Definition at line 122 of file move.h.

◆ getMoveT()

MEMBER_CONSTEXPR move_t bBasicMove::getMoveT ( ) const
inline

Definition at line 124 of file move.h.

Referenced by bGame::playGameMove().

+ Here is the caller graph for this function:

◆ getPromotion()

MEMBER_CONSTEXPR ppiece_t bBasicMove::getPromotion ( ) const
inline

Definition at line 128 of file move.h.

Referenced by bMove::getBlackPromotionPiece(), bMove::getWhitePromotionPiece(), bMove::isMajorPromotion(), and isPromotion().

+ Here is the caller graph for this function:

◆ isPromotion()

bool bBasicMove::isPromotion ( ) const
inline

Definition at line 132 of file move.h.

+ Here is the call graph for this function:

◆ setPromotion()

void bBasicMove::setPromotion ( ppiece_t const  p)
inline

Definition at line 133 of file move.h.

◆ isCapture()

bool bBasicMove::isCapture ( ) const
inline

Definition at line 134 of file move.h.

Referenced by bMove::getMoveEvalStr(), and bMove::isNonSilent().

+ Here is the caller graph for this function:

◆ setCapture()

void bBasicMove::setCapture ( )
inline

Definition at line 135 of file move.h.

Referenced by bPawn::addCapturePawnMove(), bPawn::addCapturePromotionMove(), bPawn::addEPMove(), bPiece::addMove(), and bPiece::addMoves().

+ Here is the caller graph for this function:

◆ isPawnMove()

bool bBasicMove::isPawnMove ( ) const
inline

Definition at line 136 of file move.h.

◆ isCastleMove()

bool bBasicMove::isCastleMove ( ) const
inline

Definition at line 137 of file move.h.

◆ setCastleMove()

void bBasicMove::setCastleMove ( uint16_t  f)
inline

Definition at line 138 of file move.h.

Referenced by bWhiteKing::GenerateMoves(), and bBlackKing::GenerateMoves().

+ Here is the caller graph for this function:

◆ isLongCastleMove()

bool bBasicMove::isLongCastleMove ( ) const
inline

Definition at line 139 of file move.h.

◆ isCheck()

bool bBasicMove::isCheck ( ) const
inline

Definition at line 140 of file move.h.

Referenced by bMove::getMoveEvalStr().

+ Here is the caller graph for this function:

◆ setCheck()

void bBasicMove::setCheck ( )
inline

Definition at line 141 of file move.h.

◆ isMate()

bool bBasicMove::isMate ( ) const
inline

Definition at line 142 of file move.h.

Referenced by bMove::getMoveEvalStr().

+ Here is the caller graph for this function:

◆ setMate()

void bBasicMove::setMate ( )
inline

Definition at line 143 of file move.h.

◆ isEPPossible()

bool bBasicMove::isEPPossible ( ) const
inline

Definition at line 144 of file move.h.

◆ setEPPossible()

void bBasicMove::setEPPossible ( )
inline

Definition at line 145 of file move.h.

Referenced by bPawn::addNonCaptureDoublePawnMove().

+ Here is the caller graph for this function:

◆ isEPMove()

bool bBasicMove::isEPMove ( ) const
inline

Definition at line 146 of file move.h.

Referenced by bMove::getMoveEvalStr(), and bMove::isNonSilent().

+ Here is the caller graph for this function:

◆ setEPMove()

void bBasicMove::setEPMove ( )
inline

Definition at line 147 of file move.h.

Referenced by bPawn::addEPMove().

+ Here is the caller graph for this function:

◆ setGameEnd()

void bBasicMove::setGameEnd ( const moveflags_t  e)
inline

Definition at line 148 of file move.h.

◆ getGameEnd()

bool bBasicMove::getGameEnd ( ) const
inline

Definition at line 149 of file move.h.

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  os,
bBasicMove const &  m 
)
friend

Definition at line 124 of file move.cpp.

Member Data Documentation

◆ m_bmove

basicmove_t bBasicMove::m_bmove = 0
protected

Definition at line 152 of file move.h.

Referenced by bBasicMove(), from(), getBasicMoveT(), getMoveT(), and to().

◆ m_movef