Interface IndexGraphBuilder.ReIndexedGraph

  • Enclosing interface:
    IndexGraphBuilder

    public static interface IndexGraphBuilder.ReIndexedGraph
    A result object of re-indexing and building a graph operation.

    Re-indexing is the operation of assigning new indices to the vertices/edges. By re-indexing the vertices/edges, the performance of accessing/iterating over the graph vertices/edges may increase, for example if a more cache friendly indexing exists.

    During the lifetime of a IndexGraphBuilder, vertices and edges are added to it, each one of them has a unique int identifier which is also its index (see IndexGraph). The builder can re-index the vertices/edges and build a new graph, resulting in a re-indexed graph graph(), the vertices re-indexing verticesReIndexing() and the edges re-indexing edgesReIndexing().

    Author:
    Barak Ugav
    See Also:
    IndexGraphBuilder.reIndexAndBuild(boolean, boolean), IndexGraphBuilder.ReIndexingMap
    • Method Detail

      • graph

        IndexGraph graph()
        Get the newly created re-indexed graph.
        Returns:
        the actual re-indexed graph
      • verticesReIndexing

        Optional<IndexGraphBuilder.ReIndexingMap> verticesReIndexing()
        Get the re-indexing map of the vertices.

        The returned object (if present) can map each original vertex index to its new index after re-indexing. If the returned is not present, the vertices were no re-indexed.

        Returns:
        the re-indexing map of the vertices
      • edgesReIndexing

        Optional<IndexGraphBuilder.ReIndexingMap> edgesReIndexing()
        Get the re-indexing map of the edges.

        The returned object (if present) can map each original edge index to its new index after re-indexing. If the returned is not present, the edges were no re-indexed.

        Returns:
        the re-indexing map of the edges