N - Type of nodepublic abstract class IndexedHierarchicalGraph<N> extends java.lang.Object implements IndexedGraph<N>, HierarchicalGraph<N>
IndexedAStarPathFinder.| Modifier and Type | Field and Description |
|---|---|
protected int |
level |
protected int |
levelCount |
| Constructor and Description |
|---|
IndexedHierarchicalGraph(int levelCount)
Creates an
IndexedHierarchicalGraph with the given number of levels. |
| Modifier and Type | Method and Description |
|---|---|
abstract N |
convertNodeBetweenLevels(int inputLevel,
N node,
int outputLevel)
Converts the node at the input level into a node at the output level.
|
int |
getLevelCount()
Returns the number of levels in this hierarchical graph.
|
void |
setLevel(int level)
Switches the graph into the given level so all future calls to the
getConnections methods
act as if the graph was just a simple, non-hierarchical graph at that level. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetIndex, getNodeCountgetConnectionspublic IndexedHierarchicalGraph(int levelCount)
IndexedHierarchicalGraph with the given number of levels.public int getLevelCount()
HierarchicalGraphgetLevelCount in interface HierarchicalGraph<N>public void setLevel(int level)
HierarchicalGraphgetConnections methods
act as if the graph was just a simple, non-hierarchical graph at that level.setLevel in interface HierarchicalGraph<N>level - the level to setpublic abstract N convertNodeBetweenLevels(int inputLevel, N node, int outputLevel)
HierarchicalGraphconvertNodeBetweenLevels in interface HierarchicalGraph<N>inputLevel - the input levelnode - the node at the input leveloutputLevel - the output level