osl::ki2::Ki2File Class Reference

「.ki2」という拡張子を持つ2ch形式ファイル. More...

`#include <ki2.h>`

Inheritance diagram for osl::ki2::Ki2File:

## Public Types

enum | ParseResult { OK = 0 , Komaochi , Illegal }

## Public Member Functions

| Ki2File (const std::string &filename, bool verbose=false)
Public Member Functions inherited from osl::record::RecordFile
virtual | ~RecordFile ()
Record | load () const
const NumEffectState | initialState () const
const std::vector< Move > | moves () const

## Static Public Member Functions

static ParseResult | parseLine (NumEffectState &, Record &, KanjiMove &, std::string element)

## Private Attributes

bool | verbose

## Additional Inherited Members

Protected Attributes inherited from osl::record::RecordFile
Record | record

## Detailed Description

「.ki2」という拡張子を持つ2ch形式ファイル.

ファイルはShift_JIS (Windows-31J)であることが期待され、 内部ではEUC-JPに文字変換される。

Definition at line 21 of file ki2.h.

## Member Enumeration Documentation

## ParseResult

enum osl::ki2::Ki2File::ParseResult

Enumerator
OK |
Komaochi |
Illegal |

Definition at line 28 of file ki2.h.

## Constructor & Destructor Documentation

## Ki2File()

osl::ki2::Ki2File::Ki2File | ( | const std::string & | filename,
|  | bool | verbose = false )

Definition at line 91 of file ki2.cc.

References Illegal, Komaochi, OK, parseLine(), osl::record::RecordFile::record, osl::record::KanjiMove::setVerbose(), osl::misc::sjis2euc(), and verbose.

## Member Function Documentation

## parseLine()

osl::ki2::Ki2File::ParseResult osl::ki2::Ki2File::parseLine | ( | NumEffectState & | state,
|  | Record & | record,
|  | KanjiMove & | kmove,
|  | std::string | element )

static

eliminates HH:MM part

Definition at line 12 of file ki2.cc.

References osl::BLACK, Illegal, osl::Move::isValid(), K_BLACK, K_BLACK_SIGN, K_COLON, K_KAISHI, K_KISEN, K_NICHIJI, K_RESIGN, K_SPACE, K_TEAIWARI, K_WHITE, K_WHITE_SIGN, Komaochi, osl::NumEffectState::makeMove(), OK, osl::record::RecordFile::record, osl::record::KanjiMove::strToMove(), and osl::WHITE.

Referenced by Ki2File().

## Member Data Documentation

## verbose

bool osl::ki2::Ki2File::verbose

private

Definition at line 24 of file ki2.h.

Referenced by Ki2File().

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

- ki2.h
- ki2.cc