public class CHGraphImpl extends Object implements CHGraph, Storable<CHGraph>
| Modifier and Type | Method and Description |
|---|---|
void |
close()
This method makes sure that the underlying used resources are released.
|
CHGraph |
create(long bytes)
Creates the underlying storage.
|
CHEdgeExplorer |
createEdgeExplorer() |
CHEdgeExplorer |
createEdgeExplorer(EdgeFilter filter) |
EdgeExplorer |
createOriginalEdgeExplorer() |
EdgeExplorer |
createOriginalEdgeExplorer(EdgeFilter filter) |
void |
debugPrint() |
void |
flush()
This method makes sure that the underlying data is written to the storage.
|
AllCHEdgesIterator |
getAllEdges() |
Graph |
getBaseGraph() |
long |
getCapacity() |
CHConfig |
getCHConfig()
Returns the profile of this CH graph.
|
CHEdgeIteratorState |
getEdgeIteratorState(int edgeId,
int endNode) |
int |
getEdges() |
int |
getLevel(int nodeIndex) |
NodeOrderingProvider |
getNodeOrderingProvider() |
int |
getNodes() |
int |
getOriginalEdges() |
int |
getOtherNode(int edge,
int node) |
boolean |
isAdjacentToNode(int edge,
int node) |
boolean |
isClosed() |
boolean |
isReadyForContraction() |
boolean |
isShortcut(int edgeId) |
protected int |
loadEdgesHeader() |
boolean |
loadExisting() |
protected int |
nextShortcutId() |
void |
setLevel(int nodeIndex,
int level)
This methods sets the level of the specified node.
|
int |
shortcut(int a,
int b,
int accessFlags,
double weight,
int skippedEdge1,
int skippedEdge2)
This method creates a shortcut between a to b which is nearly identical to creating an edge
except that it can be excluded or included for certain traversals or algorithms.
|
int |
shortcutEdgeBased(int a,
int b,
int accessFlags,
double weight,
int skippedEdge1,
int skippedEdge2,
int origFirst,
int origLast)
like shortcut(), but for edge-based CH
|
String |
toString() |
public CHConfig getCHConfig()
CHGraphgetCHConfig in interface CHGraphpublic boolean isShortcut(int edgeId)
isShortcut in interface CHGraphpublic final void setLevel(int nodeIndex,
int level)
CHGraphpublic final int getLevel(int nodeIndex)
public int shortcut(int a,
int b,
int accessFlags,
double weight,
int skippedEdge1,
int skippedEdge2)
CHGraphpublic int shortcutEdgeBased(int a,
int b,
int accessFlags,
double weight,
int skippedEdge1,
int skippedEdge2,
int origFirst,
int origLast)
CHGraphshortcutEdgeBased in interface CHGraphorigFirst - The first original edge that is skipped by this shortcut. For example for the following shortcut
edge from x to y, which itself skips the shortcuts x->v and v->y the first original edge would
be x->u: x->u->v->w->yorigLast - like origFirst, but the last orig edge, i.e w->y in above exampleprotected int nextShortcutId()
public CHEdgeExplorer createEdgeExplorer()
createEdgeExplorer in interface CHGraphpublic CHEdgeExplorer createEdgeExplorer(EdgeFilter filter)
createEdgeExplorer in interface CHGraphpublic EdgeExplorer createOriginalEdgeExplorer()
createOriginalEdgeExplorer in interface CHGraphpublic EdgeExplorer createOriginalEdgeExplorer(EdgeFilter filter)
createOriginalEdgeExplorer in interface CHGraphpublic final CHEdgeIteratorState getEdgeIteratorState(int edgeId, int endNode)
getEdgeIteratorState in interface CHGraphpublic int getEdges()
public int getOriginalEdges()
getOriginalEdges in interface CHGraphpublic boolean isReadyForContraction()
isReadyForContraction in interface CHGraphpublic int getOtherNode(int edge,
int node)
getOtherNode in interface CHGraphpublic boolean isAdjacentToNode(int edge,
int node)
isAdjacentToNode in interface CHGraphpublic AllCHEdgesIterator getAllEdges()
getAllEdges in interface CHGraphprotected int loadEdgesHeader()
public Graph getBaseGraph()
getBaseGraph in interface CHGraphpublic CHGraph create(long bytes)
Storablepublic boolean loadExisting()
loadExisting in interface Storable<CHGraph>public void flush()
Storablepublic void close()
Storablepublic long getCapacity()
getCapacity in interface Storable<CHGraph>public void debugPrint()
public NodeOrderingProvider getNodeOrderingProvider()
getNodeOrderingProvider in interface CHGraphCopyright © 2012–2020. All rights reserved.