public class OwareLeaves extends Book implements Leaves
All the positions on the database up to the specified number of
seeds are kept on main memory. To obtain the score of a position a
search must be performed first with the method find
.
Modifier and Type | Field and Description |
---|---|
static int |
MAX_SEEDS
Maximum number of seeds that a position can contain
|
static java.lang.String |
SIGNATURE
Header signature for the book format
|
Constructor and Description |
---|
OwareLeaves(java.io.File file,
int seeds)
Instantiates a new endgames book object.
|
Modifier and Type | Method and Description |
---|---|
boolean |
find(Game game)
Search a position provided by a
OwareGame object and sets
it as the current position on the endgames book. |
int |
getScore()
Returns the exact score value for the last position found
from south's perspective.
|
fields, finalize, getDatabase, getField, getVersion
public static final java.lang.String SIGNATURE
public static final int MAX_SEEDS
public OwareLeaves(java.io.File file, int seeds) throws java.io.IOException
file
- book fileseeds
- maximum number of seedsjava.io.IOException