Package oracle.spatial.network.lod
Class VisitedNode
- java.lang.Object
-
- oracle.spatial.network.lod.VisitedNode
-
- All Implemented Interfaces:
java.lang.Comparable,Identifiable
- Direct Known Subclasses:
AStar.AStarVisitedNode
public abstract class VisitedNode extends java.lang.Object implements Identifiable, java.lang.Comparable
This class represents a node visited while exploring a network.- Since:
- release specific (what release of product did this appear in)
-
-
Constructor Summary
Constructors Constructor Description VisitedNode()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description intcompareTo(java.lang.Object o)booleanequals(java.lang.Object o)abstract double[]getCosts()Return the costs from the start points to the node.abstract double[]getCostsAtPrevNode()Returns the costs to pass through the previous node.intgetDepth()Returns the depth of the current node, which is equal to the number of links from the start node to the current node.longgetId()Returns the ID of the node.intgetLinkLevel()Returns the link level the node is to be expanded on.intgetPartitionId()Returns the ID of the partition that the node is assigned to.longgetPrevLink()Returns the ID of the previous link.VisitedNodegetPrevNode()Returns the previous node.java.lang.ObjectgetUserObject()Returns the user object associated to this node.inthashCode()protected voidinit(long id, int depth, int linkLevel, int partitionId)protected voidinit(long id, long prevLink, VisitedNode prevNode, int depth, int linkLevel, int partitionId, java.lang.Object userObject)
-
-
-
Method Detail
-
init
protected void init(long id, int depth, int linkLevel, int partitionId)
-
init
protected void init(long id, long prevLink, VisitedNode prevNode, int depth, int linkLevel, int partitionId, java.lang.Object userObject)
-
compareTo
public int compareTo(java.lang.Object o)
- Specified by:
compareToin interfacejava.lang.Comparable
-
getId
public long getId()
Returns the ID of the node.- Specified by:
getIdin interfaceIdentifiable- Returns:
-
getPartitionId
public int getPartitionId()
Returns the ID of the partition that the node is assigned to.- Returns:
-
getCosts
public abstract double[] getCosts()
Return the costs from the start points to the node.- Returns:
-
getCostsAtPrevNode
public abstract double[] getCostsAtPrevNode()
Returns the costs to pass through the previous node.- Returns:
-
getPrevLink
public long getPrevLink()
Returns the ID of the previous link.- Returns:
-
getPrevNode
public VisitedNode getPrevNode()
Returns the previous node.- Returns:
-
getDepth
public int getDepth()
Returns the depth of the current node, which is equal to the number of links from the start node to the current node. The depth of the start node is 0.- Returns:
-
getLinkLevel
public int getLinkLevel()
Returns the link level the node is to be expanded on.- Returns:
-
getUserObject
public java.lang.Object getUserObject()
Returns the user object associated to this node.- Returns:
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
-