libgrape-lite
A C++ library for parallel graph processing
Public Member Functions | Private Member Functions | List of all members
grape::TSVLineParser< OID_T, VDATA_T, EDATA_T > Class Template Reference

a default parser for tsv files. More...

#include <tsv_line_parser.h>

Inheritance diagram for grape::TSVLineParser< OID_T, VDATA_T, EDATA_T >:
grape::LineParserBase< OID_T, VDATA_T, EDATA_T >

Public Member Functions

virtual void LineParserForEFile (const std::string &line, OID_T &u, OID_T &v, EDATA_T &e_data)
 parser of edge file, to parse source vertex_id, destination vertex_id from a line. More...
 
virtual void LineParserForVFile (const std::string &line, OID_T &u, VDATA_T &u_data)
 parser of vertex file, to parse vertex_id and vertex_data from a string. More...
 

Private Member Functions

template<typename... Ts>
const char * LineParserForEverything (const std::string &line, Ts &... vals)
 
template<typename T >
const char * LineParserForEverything (const char *head, T &val)
 
template<typename T , typename... Ts>
const char * LineParserForEverything (const char *head, T &val, Ts &... vals)
 

Detailed Description

template<typename OID_T, typename VDATA_T, typename EDATA_T>
class grape::TSVLineParser< OID_T, VDATA_T, EDATA_T >

a default parser for tsv files.

Template Parameters
OID_T
VDATA_T
EDATA_T

Member Function Documentation

◆ LineParserForEFile()

template<typename OID_T , typename VDATA_T , typename EDATA_T >
virtual void grape::TSVLineParser< OID_T, VDATA_T, EDATA_T >::LineParserForEFile ( const std::string &  line,
OID_T &  u,
OID_T &  v,
EDATA_T &  e_data 
)
inlinevirtual

parser of edge file, to parse source vertex_id, destination vertex_id from a line.

Parameters
line
u
v
e_data

Implements grape::LineParserBase< OID_T, VDATA_T, EDATA_T >.

◆ LineParserForVFile()

template<typename OID_T , typename VDATA_T , typename EDATA_T >
virtual void grape::TSVLineParser< OID_T, VDATA_T, EDATA_T >::LineParserForVFile ( const std::string &  line,
OID_T &  u,
VDATA_T &  v_data 
)
inlinevirtual

parser of vertex file, to parse vertex_id and vertex_data from a string.

Parameters
line
u
v_data

Implements grape::LineParserBase< OID_T, VDATA_T, EDATA_T >.