public static class

ADStarNode.Key

extends Object
implements Comparable<T>
java.lang.Object
   ↳ es.usc.citius.hipster.model.ADStarNode.Key<C extends java.lang.Comparable<C>>

Class Overview

Inner class defining the key of the node, which depends on the values of G and V. The key of the node is the comparison criterion for ADStarForward to order the open queue.

Summary

Public Constructors
ADStarNode.Key(C g, C v, C h, double e, BinaryOperation<C> add, ScalarFunction<C> scale)
Constructor to calculate a the key to order the nodes in the Open queue.
ADStarNode.Key(C first, C second)
Instantiates a new Key given its first and second value instead of calculating them.
Public Methods
int compareTo(Key<C> o)
Compares by the first value and, if equal, by the second one.
C getFirst()
C getSecond()
[Expand]
Inherited Methods
From class java.lang.Object
From interface java.lang.Comparable

Public Constructors

public ADStarNode.Key (C g, C v, C h, double e, BinaryOperation<C> add, ScalarFunction<C> scale)

Constructor to calculate a the key to order the nodes in the Open queue.

Parameters
g g value of the node
v v value of the node
h value of the heuristic
e inflation value

public ADStarNode.Key (C first, C second)

Instantiates a new Key given its first and second value instead of calculating them.

Parameters
first first cost value
second second cost value

Public Methods

public int compareTo (Key<C> o)

Compares by the first value and, if equal, by the second one.

Parameters
o other Key object
Returns
  • comparison result

public C getFirst ()

Returns
  • first value of the key

public C getSecond ()

Returns
  • second value of the key