osl::eval::ml::KnightCheck Class Reference

`#include <minorPiece.h>`

## Public Types

enum | { DIM = 1 }

## Static Public Member Functions

static void | setUp (const Weights &weights, int stage)
static MultiInt | eval (const NumEffectState &state)
template<Player Defense>
static bool | canCheck (const NumEffectState &state)
static MultiInt | value (int index_y)

## Static Private Member Functions

template<Player King>
static int | indexY (int y)

## Static Private Attributes

static MultiInt | weight
static CArray< MultiInt, 9 > | y_table

## Friends

class | KnightCheckY

## Detailed Description

Definition at line 776 of file minorPiece.h.

## Member Enumeration Documentation

## anonymous enum

anonymous enum

Enumerator
DIM |

Definition at line 780 of file minorPiece.h.

## Member Function Documentation

## canCheck()

template<Player Defense>

bool osl::eval::ml::KnightCheck::canCheck | ( | const NumEffectState & | state | ) |

inline static

Definition at line 784 of file minorPiece.h.

References osl::alt(), osl::NumEffectState::hasEffectAt(), osl::NumEffectState::hasEffectByPtypeStrict(), osl::SimpleState::hasPieceOnStand(), osl::Piece::isEmpty(), osl::Square::isOnBoard(), osl::Piece::isOnBoardByOwner(), osl::SimpleState::kingSquare(), osl::KNIGHT, and osl::SimpleState::pieceAt().

Referenced by osl::eval::ml::CanCheckNonPawnPieceStandCombination::canCheck(), and eval().

## eval()

MultiInt osl::eval::ml::KnightCheck::eval | ( | const NumEffectState & | state | ) |

static

Definition at line 651 of file minorPiece.cc.

References osl::BLACK, canCheck(), indexY(), osl::SimpleState::kingSquare(), value(), and osl::WHITE.

Referenced by osl::eval::ml::OpenMidEndingEval::OpenMidEndingEval(), and osl::eval::ml::OpenMidEndingEval::updateSub().

## indexY()

template<Player King>

int osl::eval::ml::KnightCheck::indexY | ( | int | y | ) |

inline static private

Definition at line 816 of file minorPiece.h.

References osl::BLACK.

Referenced by eval().

## setUp()

void osl::eval::ml::KnightCheck::setUp | ( | const Weights & | weights,
|  | int | stage )

static

Definition at line 636 of file minorPiece.cc.

References osl::eval::ml::Weights::value(), and weight.

## value()

MultiInt osl::eval::ml::KnightCheck::value | ( | int | index_y | ) |

inline static

Definition at line 812 of file minorPiece.h.

References weight, and y_table.

Referenced by eval().

## Friends And Related Symbol Documentation

## KnightCheckY

friend class KnightCheckY

friend

Definition at line 778 of file minorPiece.h.

References KnightCheckY.

Referenced by KnightCheckY.

## Member Data Documentation

## weight

MultiInt osl::eval::ml::KnightCheck::weight

static private

Definition at line 814 of file minorPiece.h.

Referenced by setUp(), and value().

## y_table

osl::CArray< MultiInt, 9 > osl::eval::ml::KnightCheck::y_table

static private

Definition at line 820 of file minorPiece.h.

Referenced by osl::eval::ml::KnightCheckY::setUp(), and value().

The documentation for this class was generated from the following files:

- minorPiece.h
- minorPiece.cc