|
Apache GraphAr C++ Library
The C++ Library for Apache GraphAr
|
#include <chunk_info_reader.h>
Public Member Functions | |
| AdjListChunkInfoReader (const std::shared_ptr< EdgeInfo > &edge_info, AdjListType adj_list_type, const std::string &prefix) | |
| Initialize the AdjListChunkInfoReader. More... | |
| Status | seek_src (IdType id) |
| Sets chunk position indicator for reader by source internal vertex id. More... | |
| Status | seek_dst (IdType id) |
| Sets chunk position indicator for reader by destination internal vertex id. More... | |
| Status | seek (IdType index) |
| Sets chunk position indicator for reader by edge index. More... | |
| Result< std::string > | GetChunk () |
| Status | next_chunk () |
Static Public Member Functions | |
| static Result< std::shared_ptr< AdjListChunkInfoReader > > | Make (const std::shared_ptr< EdgeInfo > &edge_info, AdjListType adj_list_type, const std::string &prefix) |
| Create an AdjListChunkInfoReader instance from edge info. More... | |
| static Result< std::shared_ptr< AdjListChunkInfoReader > > | Make (const std::shared_ptr< GraphInfo > &graph_info, const std::string &src_type, const std::string &edge_type, const std::string &dst_type, AdjListType adj_list_type) |
| Create an AdjListChunkInfoReader instance from graph info. More... | |
The chunk info reader for adj list topology chunk.
Definition at line 119 of file chunk_info_reader.h.
|
explicit |
Initialize the AdjListChunkInfoReader.
| edge_info | The edge info that describes the edge type. |
| adj_list_type | The adj list type for the edges. |
| prefix | The absolute prefix of the graph. |
Definition at line 113 of file chunk_info_reader.cc.
| Result< std::string > graphar::AdjListChunkInfoReader::GetChunk | ( | ) |
Return the current chunk file path of chunk position indicator.
Definition at line 208 of file chunk_info_reader.cc.
|
static |
Create an AdjListChunkInfoReader instance from edge info.
| edge_info | The edge info. |
| adj_list_type | The adj list type for the edges. |
| prefix | The absolute prefix of the graph. |
Definition at line 232 of file chunk_info_reader.cc.
|
static |
Create an AdjListChunkInfoReader instance from graph info.
| graph_info | The graph info. |
| src_type | The source vertex type. |
| edge_type | The edge type. |
| dst_type | The destination vertex type. |
| adj_list_type | The adj list type for the edges. |
Definition at line 244 of file chunk_info_reader.cc.
| Status graphar::AdjListChunkInfoReader::next_chunk | ( | ) |
Sets chunk position indicator to next chunk.
if current chunk is the last chunk, will return Status::IndexError error.
Definition at line 215 of file chunk_info_reader.cc.
| Status graphar::AdjListChunkInfoReader::seek | ( | IdType | index | ) |
Sets chunk position indicator for reader by edge index.
| offset | edge index of the vertex chunk. Note: the offset is the edge index of the vertex chunk, not the edge index of the whole graph. |
Definition at line 198 of file chunk_info_reader.cc.
| Status graphar::AdjListChunkInfoReader::seek_dst | ( | IdType | id | ) |
Sets chunk position indicator for reader by destination internal vertex id.
| id | the destination internal vertex id. |
Definition at line 166 of file chunk_info_reader.cc.
| Status graphar::AdjListChunkInfoReader::seek_src | ( | IdType | id | ) |
Sets chunk position indicator for reader by source internal vertex id.
| id | the source internal vertex id. |
Definition at line 133 of file chunk_info_reader.cc.