A filter for chess games in a PGN database.
More...
#include <pgngamefilter.h>
A filter for chess games in a PGN database.
A PgnGameFilter object can be used to filter games in a PGN database by matching the filtering terms to the games' PGN tags.
- See also
- PgnGameEntry
The result of the game.
| Enumerator |
|---|
| AnyResult |
Any result (no filtering)
|
| EitherPlayerWins |
Either player wins.
|
| WhiteWins |
The white player wins.
|
| BlackWins |
The black player wins.
|
| FirstPlayerWins |
The first player wins.
|
| FirstPlayerLoses |
The first player loses.
|
| Draw |
The game is a draw.
|
| Unfinished |
The game wasn't completed.
|
The type of the filter.
| Enumerator |
|---|
| FixedString |
Filter all tags with a single fixed string.
|
| Advanced |
Use invididual filtering terms for each tag.
|
| PgnGameFilter::PgnGameFilter |
( |
| ) |
|
Creates a new empty filter.
An empty filter will not filter out any games. The filter's type is Advanced.
| PgnGameFilter::PgnGameFilter |
( |
const QString & |
pattern | ) |
|
Creates a new filter based on a fixed string.
Games that have tags matching pattern will be filtered in. The filter's type is FixedString.
| const char * PgnGameFilter::event |
( |
| ) |
const |
|
inline |
Returns the filter for the Event tag.
| bool PgnGameFilter::isResultInverted |
( |
| ) |
const |
|
inline |
Returns true if the filter is looking for the inverse of result(); otherwise returns false.
| const QDate & PgnGameFilter::maxDate |
( |
| ) |
const |
|
inline |
Returns the filter for the game's maximum starting date.
- Note
- A null QDate won't filter out any games.
| int PgnGameFilter::maxRound |
( |
| ) |
const |
|
inline |
Returns the filter for the maximum round ordinal.
| const QDate & PgnGameFilter::minDate |
( |
| ) |
const |
|
inline |
Returns the filter for the game's minimum starting date.
- Note
- A null QDate won't filter out any games.
| int PgnGameFilter::minRound |
( |
| ) |
const |
|
inline |
Returns the filter for the minimum round ordinal.
| const char * PgnGameFilter::opponent |
( |
| ) |
const |
|
inline |
Returns the filter for the opponent of the first player.
| const char * PgnGameFilter::pattern |
( |
| ) |
const |
|
inline |
Returns the pattern for FixedString mode.
| const char * PgnGameFilter::player |
( |
| ) |
const |
|
inline |
Returns the filter for the first player.
The first player's side/color is determined by the playerSide() member function.
Returns the filter for the side/color of the first player.
Returns the filter for the Result tag.
| void PgnGameFilter::setEvent |
( |
const QString & |
event | ) |
|
Sets the Event tag filter to event.
| void PgnGameFilter::setMaxDate |
( |
const QDate & |
date | ) |
|
Sets the maximum starting date filter to date.
| void PgnGameFilter::setMaxRound |
( |
int |
round | ) |
|
Sets the maximum round ordinal filter to round.
| void PgnGameFilter::setMinDate |
( |
const QDate & |
date | ) |
|
Sets the minimum starting date filter to date.
| void PgnGameFilter::setMinRound |
( |
int |
round | ) |
|
Sets the minimum round ordinal filter to round.
| void PgnGameFilter::setOpponent |
( |
const QString & |
name | ) |
|
Sets the first player's opponent filter to name.
| void PgnGameFilter::setPattern |
( |
const QString & |
pattern | ) |
|
Sets the FixedString pattern to pattern.
This function will change the filter type to FixedString.
Sets the side player's filter to name.
| void PgnGameFilter::setResult |
( |
Result |
result | ) |
|
Sets the Result tag filter to result.
| void PgnGameFilter::setResultInverted |
( |
bool |
invert | ) |
|
Sets the resultInverted value to invert.
| void PgnGameFilter::setSite |
( |
const QString & |
site | ) |
|
Sets the Site tag filter to site.
| const char * PgnGameFilter::site |
( |
| ) |
const |
|
inline |
Returns the filter for the Site tag.
Returns the type of the filter.
The documentation for this class was generated from the following files: