private void outputSN(SearchNode sn) {
   System.out.println("------------");
   System.out.println(sn.board.toString());
   System.out.println("Moves = " + sn.moves + " Prio = " + sn.priority());
 }
Esempio n. 2
0
 @Override
 public int compareTo(SearchNode o) {
   return (int) Math.signum(priority() - o.priority());
 }
 /** Compare the SearchNode with the anchor one by priority value. */
 public int compareTo(SearchNode that) {
   if (this.priority() < that.priority()) return -1;
   else if (this.priority() > that.priority()) return 1;
   else return 0;
 }
Esempio n. 4
0
 @Override
 public int compareTo(SearchNode that) {
   return this.priority() - that.priority();
 }