Class METISParser

Class Documentation

class METISParser

Parser for the METIS file format.

Public Functions

METISParser(std::string_view path)

Constructor for the METIS Parser.

Parameters:

path[in] file path

std::tuple<count, count, index, count> getHeader()

Get the METIS graph file header

bool hasNext()

Test if graph file has a next line.

std::vector<node> getNext(count ignoreFirst = 0)

Get adjacencies from the next line in the METIS graph file.

Parameters:

ignoreFirst[in] number of values to ignore [in case the METIS file contains node weightes]

std::vector<std::pair<node, double>> getNextWithWeights(count ignoreFirst = 0)

Get adjacencies with edge weights from the next line in the METIS graph file.

Parameters:

ignoreFirst[in] number of values to ignore [in case the METIS file contains node weightes]