osl::rating::Karanari Class Reference

- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | Static Public Member Functions | Private Attributes | List of all members
osl::rating::Karanari Class Reference

`#include <karanari.h>`

Inheritance diagram for osl::rating::Karanari:
[legend]
Collaboration diagram for osl::rating::Karanari:
[legend]

## Public Member Functions
| Karanari (bool b, bool c)
bool | match (const NumEffectState &state, Move move, const RatingEnv &) const
Public Member Functions inherited from osl::rating::Feature
| Feature (const std::string &name)
virtual | ~Feature ()
virtual bool | effectiveInCheck () const
const std::string & | name () const

## Static Public Member Functions
static bool | matchGeneral (const NumEffectState &state, Move move)
static int | index (const NumEffectState &state, Move move)

## Private Attributes
bool | bishop
bool | can_promote_area

## Detailed Description

Definition at line 13 of file karanari.h.

## Constructor & Destructor Documentation

osl::rating::Karanari::Karanari | ( | bool | b,
|  | bool | c
| ) |  |
| inline

Definition at line 17 of file karanari.h.

## Member Function Documentation

static int osl::rating::Karanari::index | ( | const NumEffectState & | state,
|  | Move | move
| ) |  |
| inlinestatic

Definition at line 41 of file karanari.h.

References osl::Square::canPromote(), osl::Neighboring8::isNeighboring8(), matchGeneral(), osl::PBISHOP, osl::Move::player(), osl::PROOK, osl::Move::ptype(), and osl::Move::to().

Referenced by osl::rating::KaranariGroup::findMatch().

bool osl::rating::Karanari::match | ( | const NumEffectState & | state,
|  | Move | move,
|  | const RatingEnv & |
| ) |  | const
| inlinevirtual

Implements osl::rating::Feature.

Definition at line 29 of file karanari.h.

References bishop, can_promote_area, osl::Square::canPromote(), osl::Neighboring8::isNeighboring8(), matchGeneral(), osl::PBISHOP, osl::Move::player(), osl::PROOK, osl::Move::ptype(), and osl::Move::to().

static bool osl::rating::Karanari::matchGeneral | ( | const NumEffectState & | state,
|  | Move | move
| ) |  |
| inlinestatic

Definition at line 18 of file karanari.h.

References osl::alt(), osl::Square::canPromote(), osl::Move::capturePtype(), osl::Move::from(), osl::move_generator::addeffect8::hasEffect(), osl::Move::isPromotion(), osl::Move::oldPtypeO(), osl::PTYPE_EMPTY, osl::Move::ptypeO(), and osl::Move::to().

Referenced by index(), and match().

## Member Data Documentation

bool osl::rating::Karanari::bishop
| private

Definition at line 15 of file karanari.h.

Referenced by match().

bool osl::rating::Karanari::can_promote_area
| private

Definition at line 15 of file karanari.h.

Referenced by match().

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

- karanari.h