class GraphTile extends AnyRef

Contains the routing graph data for a single tile.

The graph topology is stored in compressed sparse row graph format. It also contains information on how the graph partitions are interconnected, i.e. graph edges from this tile to another.

Vertex indices 0 through firstEdgeIndices.length - 2 refer to internal vertices (vertices in this partition).

The last entry of firstEdgeIndices is always edges.length.

Thus, each entry in firstEdgeIndices is the index of the edge after the last edge of the previous vertex.

That means, the edges starting at a given internal vertex with index idx, are determined by the index range from firstEdgeIndices(idx) (inclusive) to firstEdgeIndices(idx + 1) (exclusive).

Vertex indices firstEdgeIndices.length - 1 through firstEdgeIndices.length + externalVertexIndices.length - 2 refer to external vertices (vertices outside this partition that are referred to from inside this partition).

Therefore, the number of external vertices is externalVertexIndices.length.

When looking up a vertex v with index idx:

  • If idx < firstEdgeIndices.length - 1, v is in the current graph partition.
  • Otherwise, v belongs to the tile with ID externalVertexTileIds(idx - firstEdgeIndices.length + 1) and its index in that partition is externalVertexIndices(idx - firstEdgeIndices.length + 1).

See also

  • TiledGraph
  • The section on "The Compressed Sparse Row Format" in the Location Library developer guide
Note

Although this object contains Arrays, you should treat it as immutable.

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. GraphTile
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new GraphTile(tileId: TileId, firstEdgeIndices: Array[Int], edges: Array[Int], externalVertexTileIds: Array[Long], externalVertexIndices: Array[Int])

    firstEdgeIndices

    For every vertex, the index of its first edge. The value at a given index v corresponds to the index of the first edge that starts at the vertex in this partition with vertex index v

    edges

    For every edge, the index of its target vertex. The value at a given index e corresponds to the index of the target vertex of the edge with index e in this partition

    externalVertexTileIds

    The tile ID of each vertex in another tile that is the target of at least one edge starting at a vertex in this tile

    externalVertexIndices

    The vertex index of each vertex in another tile that is the target of at least one edge starting at a vertex in this tile

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  6. val edges: Array[Int]
  7. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  8. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  9. def externalVertexCount: Int

    The number of external vertices referenced by this GraphTile.

    The number of external vertices referenced by this GraphTile.

    An external vertex is a vertex that belongs to another GraphTile but is the target of at least one edge originating at a vertex belonging to this tile.

    Annotations
    @inline()
  10. val externalVertexIndices: Array[Int]
  11. val externalVertexTileIds: Array[Long]
  12. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  13. val firstEdgeIndices: Array[Int]
  14. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  15. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  16. def internalEdgeCount: Int

    The number of edges whose source vertex belong to this GraphTile.

    The number of edges whose source vertex belong to this GraphTile.

    Annotations
    @inline()
  17. def internalVertexCount: Int

    The number of vertices that belong to this GraphTile.

    The number of vertices that belong to this GraphTile.

    Annotations
    @inline()
  18. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  19. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  20. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  21. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  22. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  23. val tileId: TileId
  24. def toString(): String
    Definition Classes
    AnyRef → Any
  25. def vertexCount: Int

    The total number of internal and external Vertices in this GraphTile.

    The total number of internal and external Vertices in this GraphTile.

    Annotations
    @inline()
  26. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  27. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  28. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()

Inherited from AnyRef

Inherited from Any

Ungrouped