GraphChi 0.1

- Main Page
- Namespaces
- Classes
- Files

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Macros
graphchi_program.hpp
Go to the documentation of this file.
1
2
32 #ifndef GRAPHCHI_PROGRAM_DEF
33 #define GRAPHCHI_PROGRAM_DEF
34
35 #include "api/graph_objects.hpp"
36 #include "api/graphchi_context.hpp"
37
38 namespace graphchi {
39
40 template <typename VertexDataType_, typename EdgeDataType_,
41 typename vertex_t = graphchi_vertex<VertexDataType_, EdgeDataType_> >
42 class GraphChiProgram {
43
44 public:
45 typedef VertexDataType_ VertexDataType;
46 typedef EdgeDataType_ EdgeDataType;
47
48 virtual ~GraphChiProgram() {}
49
53 virtual void before_iteration(int iteration, graphchi_context &gcontext) {
54 }
55
59 virtual void after_iteration(int iteration, graphchi_context &gcontext) {
60 }
61
65 virtual void before_exec_interval(vid_t window_st, vid_t window_en, graphchi_context &gcontext) {
66 }
67
71 virtual void after_exec_interval(vid_t window_st, vid_t window_en, graphchi_context &gcontext) {
72 }
73
77 virtual void update(vertex_t &v, graphchi_context &gcontext) = 0;
78 };
79
80 }
81
82 #endif
83