Esempio n. 1
0
 /**
  * Sets the entry in the table at the given key to the given value, returning the entry that was
  * stored in that location
  *
  * @param key the key value to perform the lookup at
  * @param value the value to set the entry to
  * @return the entry previously stored in the given location, null if nothing
  */
 public Transposition set(ZobristKey key, Transposition value) {
   Transposition oldValue = table[squashKey(key.getKey())];
   table[squashKey(key.getKey())] = value;
   return oldValue;
 }
Esempio n. 2
0
 /**
  * Returns the Transposition entry stored at the given key value, or null
  *
  * @param key the key value to perform the lookup with
  * @return the Transposition entry stored at the given key value, or null
  */
 public Transposition get(ZobristKey key) {
   return table[squashKey(key.getKey())];
 }