mirror of
https://gitlab.com/manzerbredes/chess-move-interface.git
synced 2025-04-07 02:26:30 +02:00
Update README.md
This commit is contained in:
parent
bbbe18df2f
commit
af333f9ff1
1 changed files with 15 additions and 15 deletions
30
README.md
30
README.md
|
@ -29,21 +29,21 @@ Load PGN from string:
|
||||||
}
|
}
|
||||||
Various API calls:
|
Various API calls:
|
||||||
|
|
||||||
pgn.HasTag("Round"); // Check if tag exists
|
pgn.HasTag("Round"); // Check if tag exists
|
||||||
try {
|
try {
|
||||||
pgn.STRCheck(); // Perform a Seven Tag Roster check
|
pgn.STRCheck(); // Perform a Seven Tag Roster check
|
||||||
}
|
}
|
||||||
catch(...){
|
catch(...){
|
||||||
// Handle exceptions
|
// Handle exceptions
|
||||||
}
|
}
|
||||||
std::vector<std::string> tags=pgn.GetTagList(); // Get a list of tags
|
std::vector<std::string> tags=pgn.GetTagList(); // Get a list of tags
|
||||||
std::string tagValue=GetTagValue("Date"); // Get the value of a tag
|
std::string tagValue=GetTagValue("Date"); // Get the value of a tag
|
||||||
Access to moves:
|
Access to moves:
|
||||||
|
|
||||||
pgnp::HalfMove *move=pgn.GetMoves(); // Get the tree of half moves
|
pgnp::HalfMove *move=pgn.GetMoves(); // Get the tree of half moves
|
||||||
int length=move->GetLength(); // Get the number of half moves in the move MainLine
|
int length=move->GetLength(); // Get the number of half moves in the move MainLine
|
||||||
// Public members:
|
// Public members:
|
||||||
// move->variations contains variations of the current move
|
// move->variations contains variations of the current move
|
||||||
// move->isBlack boolean that says if current half move is for the black side
|
// move->isBlack boolean that says if current half move is for the black side
|
||||||
// Check pgnp.hpp for more infos for other field (comments, count, etc.)
|
// Check pgnp.hpp for more infos for other field (comments, count, etc.)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue