#include <pattern.h>
Public Member Functions | |
PatternBlock (Ptype s, Ptype a, LongTarget t) | |
bool | match (const NumEffectState &state, Move move, const RatingEnv &env) const |
Static Public Member Functions | |
static const PieceSquare | find (const NumEffectState &state, Move move, Ptype attacker_ptype) |
Private Attributes | |
Ptype | self |
Ptype | attack |
LongTarget | target |
osl::rating::PatternBlock::PatternBlock | ( | Ptype | s, |
Ptype | a, | ||
LongTarget | t | ||
) |
Definition at line 98 of file pattern.cc.
const osl::rating::PieceSquare osl::rating::PatternBlock::find | ( | const NumEffectState & | state, |
Move | move, | ||
Ptype | attacker_ptype | ||
) | [static] |
Definition at line 105 of file pattern.cc.
References osl::alt(), osl::BISHOP, osl::Board_Table, osl::Piece::EDGE(), osl::BoardTable::getShortOffset(), osl::Piece::isPiece(), osl::LANCE, osl::rating::PatternLong::nextPieceOrEnd(), osl::Piece::ptype(), osl::ROOK, osl::Piece::square(), osl::Square::STAND(), and osl::Move::to().
Referenced by osl::rating::PatternBlockGroup::findMatch(), and match().
bool osl::rating::PatternBlock::match | ( | const NumEffectState & | state, |
Move | move, | ||
const RatingEnv & | env | ||
) | const [inline, virtual] |
Implements osl::rating::Feature.
Definition at line 180 of file pattern.h.
References osl::alt(), attack, find(), osl::rating::LongTarget::matchOtherThanPromotable(), osl::Move::player(), osl::rating::LongTarget::promotable, osl::Move::ptype(), and target.
Ptype osl::rating::PatternBlock::attack [private] |
Ptype osl::rating::PatternBlock::self [private] |
LongTarget osl::rating::PatternBlock::target [private] |