-
Notifications
You must be signed in to change notification settings - Fork 0
/
Heap.h
40 lines (26 loc) · 768 Bytes
/
Heap.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#ifndef HEAP_H
#define HEAP_H
#include "TwoWayList.h"
#include "Record.h"
#include "Schema.h"
#include "File.h"
#include "Comparison.h"
#include "ComparisonEngine.h"
#include "GenericDBFile.h"
// typedef enum {
// heap, sorted, tree
// } fType;
// stub DBFile header..replace it with your own DBFile.h
class Heap : virtual public GenericDBFile {
public:
Heap();
virtual int Create(const char *fpath, void *startup);
// Opens bin files
virtual int Open(const char *fpath);
// Loads a tbl file. Call Create() before this
virtual void Load(Schema &myschema, const char *loadpath);
virtual void Add(Record *addme);
virtual int GetNext(Record &fetchme, CNF &cnf, Record &literal);
virtual ~Heap() = default;
};
#endif