osl::record::Characters Class Referenceabstract

駒の文字を管理するAbstract class。 More...

`#include <kanjiPrint.h>`

Inheritance diagram for osl::record::Characters:

## Public Member Functions

virtual | ~Characters ()
virtual const std::string & | getDan (const size_t index) const =0
| 段数の文字を返す
virtual const std::string & | getSuji (const size_t index) const =0
| 筋の文字を返す。駒の文字幅に合わせる必要がある。
virtual const std::string & | getPiece (const size_t index) const =0
| 盤面上の駒を返す
const std::string & | getStand (const size_t index) const
| 持ち駒の漢字文字を返す。1文字を期待する
const std::string & | stand_kanji (const PtypeO &ptypeo) const
const std::string & | kanji (const PtypeO &ptypeo) const
const std::string & | kanji (Ptype ptype) const

## Static Public Attributes

static const CArray< std::string, 32 > | stand

## Private Member Functions

size_t | piece_index (const PtypeO &ptypeo) const

## Detailed Description

駒の文字を管理するAbstract class。

Definition at line 97 of file kanjiPrint.h.

## Constructor & Destructor Documentation

## ~Characters()

osl::record::Characters::~Characters | ( |  | ) |

virtual

Definition at line 96 of file kanjiPrint.cc.

## Member Function Documentation

## getDan()

virtual const std::string & osl::record::Characters::getDan | ( | const size_t | index | ) | const

pure virtual

段数の文字を返す

Implemented in osl::record::KIFCharacters, osl::record::RussianCharacters, and osl::record::StandardCharacters.

## getPiece()

virtual const std::string & osl::record::Characters::getPiece | ( | const size_t | index | ) | const

pure virtual

盤面上の駒を返す

Implemented in osl::record::KIFCharacters, osl::record::RussianCharacters, and osl::record::StandardCharacters.

Referenced by kanji().

## getStand()

const std::string & osl::record::Characters::getStand | ( | const size_t | index | ) | const

inline

持ち駒の漢字文字を返す。1文字を期待する

Definition at line 112 of file kanjiPrint.h.

Referenced by stand_kanji().

## getSuji()

virtual const std::string & osl::record::Characters::getSuji | ( | const size_t | index | ) | const

pure virtual

筋の文字を返す。駒の文字幅に合わせる必要がある。

Implemented in osl::record::KIFCharacters, osl::record::RussianCharacters, and osl::record::StandardCharacters.

## kanji() [1/2]

const std::string & osl::record::Characters::kanji | ( | const PtypeO & | ptypeo | ) | const

inline

Definition at line 122 of file kanjiPrint.h.

References getPiece(), and piece_index().

## kanji() [2/2]

const std::string & osl::record::Characters::kanji | ( | Ptype | ptype | ) | const

inline

Definition at line 126 of file kanjiPrint.h.

## piece_index()

size_t osl::record::Characters::piece_index | ( | const PtypeO & | ptypeo | ) | const

inline private

Definition at line 131 of file kanjiPrint.h.

References osl::PTYPEO_MAX, and osl::PTYPEO_MIN.

Referenced by kanji(), and stand_kanji().

## stand_kanji()

const std::string & osl::record::Characters::stand_kanji | ( | const PtypeO & | ptypeo | ) | const

inline

Definition at line 117 of file kanjiPrint.h.

References getStand(), and piece_index().

## Member Data Documentation

## stand

const osl::CArray< std::string, 32 > osl::record::Characters::stand

static

Initial value:
=
{{
K_NAKAGURO, "+E",
K_PPAWN, K_PLANCE, K_PKNIGHT, K_PSILVER, K_PBISHOP, K_PROOK, K_KING,
K_GOLD, K_PAWN, K_LANCE, K_KNIGHT, K_SILVER, K_BISHOP, K_ROOK,
K_NAKAGURO, "+E",
K_PPAWN, K_PLANCE, K_PKNIGHT, K_PSILVER, K_PBISHOP, K_PROOK, K_KING,
K_GOLD, K_PAWN, K_LANCE, K_KNIGHT, K_SILVER, K_BISHOP, K_ROOK
}}
K_PSILVER
#define K_PSILVER
Definition kanjiCode.h:74
K_KNIGHT
#define K_KNIGHT
Definition kanjiCode.h:67
K_NAKAGURO
#define K_NAKAGURO
Definition kanjiCode.h:16
K_PLANCE
#define K_PLANCE
Definition kanjiCode.h:64
K_GOLD
#define K_GOLD
Definition kanjiCode.h:77
K_LANCE
#define K_LANCE
Definition kanjiCode.h:62
K_ROOK
#define K_ROOK
Definition kanjiCode.h:83
K_KING
#define K_KING
Definition kanjiCode.h:88
K_PAWN
#define K_PAWN
Definition kanjiCode.h:58
K_PPAWN
#define K_PPAWN
Definition kanjiCode.h:60
K_BISHOP
#define K_BISHOP
Definition kanjiCode.h:79
K_PBISHOP
#define K_PBISHOP
Definition kanjiCode.h:81
K_PKNIGHT
#define K_PKNIGHT
Definition kanjiCode.h:69
K_SILVER
#define K_SILVER
Definition kanjiCode.h:72
K_PROOK
#define K_PROOK
Definition kanjiCode.h:85

Definition at line 100 of file kanjiPrint.h.

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

- kanjiPrint.h
- kanjiPrint.cc