Container of moves to check duplicated games. [詳細]
#include <checkDuplicate.h>
Public 型 | |
enum | DUPLICATE_RESULT { NO_DUPLICATE = 0, HASH_DUPLICATE = 1, MOVES_DUPLICATE = 2 } |
Result type of checking duplicates. [詳細] | |
Public メソッド | |
CheckDuplicate () | |
Constructor. | |
DUPLICATE_RESULT | regist (const vector< Move > &moves) |
Insert a key if the key is new. | |
void | print (std::ostream &out) const |
Output the result. | |
size_t | getRegists () const |
Return a couter of registings (trials). | |
size_t | getDuplicatedHash () const |
Return a counter of duplicated ending states. | |
size_t | getDuplicatedMoves () const |
Return a counter of duplicated moves. | |
Static Public メソッド | |
static std::pair< HashKey, PathEncoding > | getLastState (const vector< Move > &moves) |
Private 型 | |
typedef hash_map< HashKey, vector< PathEncoding > > | keymap_t |
Private メソッド | |
DUPLICATE_RESULT | regist (const HashKey &key, const PathEncoding &moves) |
Insert a key if the key is new. | |
Private 変数 | |
keymap_t | keys |
container of moves | |
size_t | regist_counter |
couter for registing (trials) | |
size_t | duplicated_hash_counter |
counter for hash matches with different moves | |
size_t | duplicated_moves_counter |
counter for exact matches of moves |
Container of moves to check duplicated games.
checkDuplicate.h の 20 行で定義されています。
typedef hash_map<HashKey, vector<PathEncoding> > osl::record::CheckDuplicate::keymap_t [private] |
checkDuplicate.h の 22 行で定義されています。
Result type of checking duplicates.
checkDuplicate.h の 38 行で定義されています。
osl::record::CheckDuplicate::CheckDuplicate | ( | ) | [inline] |
Constructor.
checkDuplicate.h の 48 行で定義されています。
size_t osl::record::CheckDuplicate::getDuplicatedHash | ( | ) | const [inline] |
Return a counter of duplicated ending states.
The moves may or may not match.
checkDuplicate.h の 80 行で定義されています。
size_t osl::record::CheckDuplicate::getDuplicatedMoves | ( | ) | const [inline] |
std::pair< osl::HashKey, osl::PathEncoding > osl::record::CheckDuplicate::getLastState | ( | const vector< Move > & | moves | ) | [static] |
checkDuplicate.cc の 8 行で定義されています。
参照先 osl::BLACK, osl::HIRATE, と osl::PathEncoding::pushMove().
参照元 regist().
size_t osl::record::CheckDuplicate::getRegists | ( | ) | const [inline] |
void osl::record::CheckDuplicate::print | ( | std::ostream & | out | ) | const |
Output the result.
checkDuplicate.cc の 62 行で定義されています。
参照先 duplicated_hash_counter, duplicated_moves_counter, keys, と regist_counter.
参照元 main().
osl::record::CheckDuplicate::DUPLICATE_RESULT osl::record::CheckDuplicate::regist | ( | const HashKey & | key, | |
const PathEncoding & | moves | |||
) | [private] |
Insert a key if the key is new.
key | a hash key of the last state of the moves | |
moves |
checkDuplicate.cc の 30 行で定義されています。
参照先 duplicated_hash_counter, duplicated_moves_counter, osl::find(), HASH_DUPLICATE, keys, MOVES_DUPLICATE, NO_DUPLICATE, と regist_counter.
osl::record::CheckDuplicate::DUPLICATE_RESULT osl::record::CheckDuplicate::regist | ( | const vector< Move > & | moves | ) |
Insert a key if the key is new.
The key is the last state of the moves.
moves |
checkDuplicate.cc の 23 行で定義されています。
参照先 getLastState().
参照元 convert(), process(), と readFile().
size_t osl::record::CheckDuplicate::duplicated_hash_counter [private] |
counter for hash matches with different moves
checkDuplicate.h の 28 行で定義されています。
参照元 getDuplicatedHash(), print(), と regist().
size_t osl::record::CheckDuplicate::duplicated_moves_counter [private] |
counter for exact matches of moves
checkDuplicate.h の 30 行で定義されています。
参照元 getDuplicatedMoves(), print(), と regist().
keymap_t osl::record::CheckDuplicate::keys [private] |
size_t osl::record::CheckDuplicate::regist_counter [private] |
couter for registing (trials)
checkDuplicate.h の 26 行で定義されています。
参照元 getRegists(), print(), と regist().