-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathIterator.h
More file actions
30 lines (26 loc) · 811 Bytes
/
Iterator.h
File metadata and controls
30 lines (26 loc) · 811 Bytes
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
#ifndef Iterator_H
#define Iterator_H
#include <nan.h>
#include "rocksdb/db.h"
using namespace std;
class Iterator : public Nan::ObjectWrap {
public:
static void Init();
static void NewInstance(const Nan::FunctionCallbackInfo<v8::Value>& args);
//static void NewInstance(const Nan::FunctionCallbackInfo &args);
rocksdb::Iterator* _it;
private:
explicit Iterator(rocksdb::ReadOptions options, rocksdb::ColumnFamilyHandle *handle, rocksdb::DB* db);
~Iterator();
static NAN_METHOD(New);
static NAN_METHOD(SeekToFirst);
static NAN_METHOD(SeekToLast);
static NAN_METHOD(Seek);
static NAN_METHOD(Valid);
static NAN_METHOD(Next);
static NAN_METHOD(Prev);
static NAN_METHOD(Key);
static NAN_METHOD(Value);
static NAN_METHOD(Status);
};
#endif // Iterator_H