diff options
Diffstat (limited to 'src/base_object.h')
-rw-r--r-- | src/base_object.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/base_object.h b/src/base_object.h index 090bb70aeb..4796a052c0 100644 --- a/src/base_object.h +++ b/src/base_object.h @@ -73,6 +73,15 @@ class BaseObject : public MemoryRetainer { static inline v8::Local<v8::FunctionTemplate> MakeLazilyInitializedJSTemplate( Environment* env); + // Setter/Getter pair for internal fields that can be passed to SetAccessor. + template <int Field> + static void InternalFieldGet(v8::Local<v8::String> property, + const v8::PropertyCallbackInfo<v8::Value>& info); + template <int Field, bool (v8::Value::* typecheck)() const> + static void InternalFieldSet(v8::Local<v8::String> property, + v8::Local<v8::Value> value, + const v8::PropertyCallbackInfo<void>& info); + private: BaseObject(); |