Add object() accessor for Dictionary.

This commit is contained in:
Cheng Zhao 2014-06-23 21:11:00 +08:00
parent c79aecf64d
commit 730acd59c7

View file

@ -24,7 +24,7 @@ namespace mate {
// //
class Dictionary { class Dictionary {
public: public:
explicit Dictionary(v8::Isolate* isolate); explicit Dictionary(v8::Isolate* isolate = NULL);
Dictionary(v8::Isolate* isolate, v8::Handle<v8::Object> object); Dictionary(v8::Isolate* isolate, v8::Handle<v8::Object> object);
~Dictionary(); ~Dictionary();
@ -48,6 +48,7 @@ class Dictionary {
CallbackTraits<T>::CreateTemplate(isolate_, callback)->GetFunction()); CallbackTraits<T>::CreateTemplate(isolate_, callback)->GetFunction());
} }
v8::Handle<v8::Object> object() const { return object_; }
v8::Isolate* isolate() const { return isolate_; } v8::Isolate* isolate() const { return isolate_; }
private: private: