Rubber stamped by hyatt.
[WebKit-https.git] / JavaScriptGlue / JSValueWrapper.h
1 #ifndef __JSValueWrapper_h
2 #define __JSValueWrapper_h
3
4 /*
5         JSValueWrapper.h
6 */
7
8 #include "JSUtils.h"
9 #include "JSBase.h"
10 #include "JSObject.h"
11
12 class JSValueWrapper {
13         public:
14                 JSValueWrapper(const Value& inValue, ExecState *inExec);
15                 virtual ~JSValueWrapper();
16
17                 Value& GetValue();
18                 ExecState* GetExecState() const;
19         
20                 ProtectedValue fValue;
21                 ExecState* fExec;
22
23                 static void GetJSObectCallBacks(JSObjectCallBacks& callBacks);
24                         
25         private:
26                 static void JSObjectDispose(void* data);
27                 static CFArrayRef JSObjectCopyPropertyNames(void* data);
28                 static JSObjectRef JSObjectCopyProperty(void* data, CFStringRef propertyName);
29                 static void JSObjectSetProperty(void* data, CFStringRef propertyName, JSObjectRef jsValue);
30                 static JSObjectRef JSObjectCallFunction(void* data, JSObjectRef thisObj, CFArrayRef args);
31                 static CFTypeRef JSObjectCopyCFValue(void* data);
32                 static void JSObjectMark(void* data);
33 };
34
35
36 #endif