My Project
osl::record::Record Struct Reference

#include <record.h>

Public Types

enum  ResultType {
  Unknown =0 , BlackWin =1 , WhiteWin =2 , Sennnichite =3 ,
  JiShogi =4
}

Public Member Functions

 Record ()
 ~Record ()
NumEffectState initialState () const
std::vector< Movemoves () const
void setDate (const std::string &date_str)
void setMoveComment (const std::string &)
void setMoveInfo (const SearchInfo &)
void setMoveTime (int)
Move lastMove () const
void load (std::vector< Move > &moves, std::vector< int > &times) const
void load (std::vector< Move > &moves, std::vector< int > &times, std::vector< std::string > &comments, std::vector< SearchInfo > &move_info) const

Static Public Member Functions

static void addWithNewLine (std::string &a, const std::string &b)

Public Attributes

RecordMinimal record
std::vector< int > times
std::vector< std::string > comments
std::vector< SearchInfomove_info
std::string version
std::string initial_comment
std::string tournament_name
CArray< std::string, 2 > player
ResultType result
boost::gregorian::date start_date

Detailed Description

Definition at line 14 of file record.h.

Member Enumeration Documentation

◆ ResultType

Enumerator
Unknown 
BlackWin 
WhiteWin 
Sennnichite 
JiShogi 

Definition at line 17 of file record.h.

Constructor & Destructor Documentation

◆ Record()

osl::record::Record::Record ( )

Definition at line 10 of file record.cc.

References result, and Unknown.

◆ ~Record()

osl::record::Record::~Record ( )

Definition at line 13 of file record.cc.

Member Function Documentation

◆ addWithNewLine()

void osl::record::Record::addWithNewLine ( std::string & a,
const std::string & b )
inlinestatic

Definition at line 35 of file record.h.

Referenced by osl::record::CsaFile::parseLine(), and setMoveComment().

◆ initialState()

Definition at line 40 of file record.h.

References record.

◆ lastMove()

Definition at line 47 of file record.h.

References moves().

◆ load() [1/2]

void osl::record::Record::load ( std::vector< Move > & moves,
std::vector< int > & times ) const
inline

Definition at line 49 of file record.h.

References moves(), record, and times.

Referenced by load().

◆ load() [2/2]

void osl::record::Record::load ( std::vector< Move > & moves,
std::vector< int > & times,
std::vector< std::string > & comments,
std::vector< SearchInfo > & move_info ) const
inline

Definition at line 53 of file record.h.

References comments, load(), move_info, moves(), and times.

◆ moves()

std::vector< Move > osl::record::Record::moves ( ) const
inline

Definition at line 41 of file record.h.

References record.

Referenced by lastMove(), load(), load(), setMoveComment(), setMoveInfo(), and setMoveTime().

◆ setDate()

void osl::record::Record::setDate ( const std::string & date_str)

◆ setMoveComment()

void osl::record::Record::setMoveComment ( const std::string & msg)

Definition at line 17 of file record.cc.

References addWithNewLine(), comments, initial_comment, and moves().

◆ setMoveInfo()

void osl::record::Record::setMoveInfo ( const SearchInfo & info)

Definition at line 26 of file record.cc.

References move_info, and moves().

◆ setMoveTime()

void osl::record::Record::setMoveTime ( int s)

Definition at line 33 of file record.cc.

References moves(), and times.

Member Data Documentation

◆ comments

std::vector<std::string> osl::record::Record::comments

Definition at line 25 of file record.h.

Referenced by load(), and setMoveComment().

◆ initial_comment

Definition at line 28 of file record.h.

Referenced by setMoveComment().

◆ move_info

Definition at line 26 of file record.h.

Referenced by load(), and setMoveInfo().

◆ player

Definition at line 29 of file record.h.

Referenced by osl::record::operator<<().

◆ record

◆ result

Definition at line 30 of file record.h.

Referenced by Record().

◆ start_date

boost::gregorian::date osl::record::Record::start_date

Definition at line 31 of file record.h.

Referenced by setDate().

◆ times

std::vector<int> osl::record::Record::times

Definition at line 24 of file record.h.

Referenced by load(), load(), and setMoveTime().

◆ tournament_name

Definition at line 28 of file record.h.

◆ version

Definition at line 28 of file record.h.

Referenced by osl::record::operator<<().


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