Package dev.roanh.cpqindex
Class IndexUtil
java.lang.Object
dev.roanh.cpqindex.IndexUtil
Collection of some small index utilities.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic dev.roanh.gmark.util.UniqueGraph<Integer,
dev.roanh.gmark.core.graph.Predicate> readGraph
(InputStream in) Reads a graph from the given plain text input stream each line is expected to contain information for a graph edge in the formatsource target label
static dev.roanh.gmark.util.UniqueGraph<Integer,
dev.roanh.gmark.core.graph.Predicate> Reads a graph from the given file where each line is expected to contain information for a graph edge in the formatsource target label
-
Constructor Details
-
IndexUtil
public IndexUtil()
-
-
Method Details
-
readGraph
public static dev.roanh.gmark.util.UniqueGraph<Integer,dev.roanh.gmark.core.graph.Predicate> readGraph(Path file) throws IOException Reads a graph from the given file where each line is expected to contain information for a graph edge in the formatsource target label
- Parameters:
file
- The file to read from.- Returns:
- The read graph.
- Throws:
IOException
- When an IOException occurs.
-
readGraph
public static dev.roanh.gmark.util.UniqueGraph<Integer,dev.roanh.gmark.core.graph.Predicate> readGraph(InputStream in) throws IOException Reads a graph from the given plain text input stream each line is expected to contain information for a graph edge in the formatsource target label
- Parameters:
in
- The input stream to read from (plain text).- Returns:
- The read graph.
- Throws:
IOException
- When an IOException occurs.
-