forked from c4milo/v8-profiler
-
Notifications
You must be signed in to change notification settings - Fork 1
/
heap_profiler.h
30 lines (23 loc) · 857 Bytes
/
heap_profiler.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
#ifndef NODE_HEAP_PROFILER_
#define NODE_HEAP_PROFILER_
#include <v8-profiler.h>
#include <node.h>
using namespace v8;
using namespace node;
namespace nodex {
class HeapProfiler {
public:
static void Initialize(Handle<Object> target);
HeapProfiler();
virtual ~HeapProfiler();
protected:
static Handle<Value> GetSnapshotsCount(const Arguments& args);
static Handle<Value> GetSnapshot(const Arguments& args);
static Handle<Value> FindSnapshot(const Arguments& args);
static Handle<Value> TakeSnapshot(const Arguments& args);
static Handle<Value> DeleteAllSnapshots(const Arguments& args);
private:
static Persistent<ObjectTemplate> heap_profiler_template_;
};
} //namespace nodex
#endif // NODE_HEAP_PROFILER_H