PythonMonkey   v1.1.1 (dev)
Loading...
Searching...
No Matches
PyDictProxyHandler.hh
Go to the documentation of this file.
1
11#ifndef PythonMonkey_PyDictProxy_
12#define PythonMonkey_PyDictProxy_
13
15
16
22public:
24 static const char family;
25
35 bool ownPropertyKeys(JSContext *cx, JS::HandleObject proxy,
36 JS::MutableHandleIdVector props) const override;
47 bool delete_(JSContext *cx, JS::HandleObject proxy, JS::HandleId id,
48 JS::ObjectOpResult &result) const override;
58 bool has(JSContext *cx, JS::HandleObject proxy, JS::HandleId id,
59 bool *bp) const override;
72 bool set(JSContext *cx, JS::HandleObject proxy, JS::HandleId id,
73 JS::HandleValue v, JS::HandleValue receiver,
74 JS::ObjectOpResult &result) const override;
84 bool enumerate(JSContext *cx, JS::HandleObject proxy,
85 JS::MutableHandleIdVector props) const override;
86
97 bool hasOwn(JSContext *cx, JS::HandleObject proxy, JS::HandleId id,
98 bool *bp) const override;
99
110 JSContext *cx, JS::HandleObject proxy,
111 JS::MutableHandleIdVector props) const override;
112
114 JSContext *cx, JS::HandleObject proxy, JS::HandleId id,
115 JS::MutableHandle<mozilla::Maybe<JS::PropertyDescriptor>> desc
116 ) const override;
117
118 bool defineProperty(JSContext *cx, JS::HandleObject proxy,
119 JS::HandleId id,
120 JS::Handle<JS::PropertyDescriptor> desc,
121 JS::ObjectOpResult &result) const override;
122
123 bool getBuiltinClass(JSContext *cx, JS::HandleObject proxy, js::ESClass *cls) const override;
124};
125
126#endif
Struct for creating JS proxy objects for all objects.
This struct is the ProxyHandler for JS Proxy Objects pythonmonkey creates to handle coercion from pyt...
Definition PyDictProxyHandler.hh:21
bool getOwnPropertyDescriptor(JSContext *cx, JS::HandleObject proxy, JS::HandleId id, JS::MutableHandle< mozilla::Maybe< JS::PropertyDescriptor > > desc) const override
Definition PyDictProxyHandler.cc:53
bool enumerate(JSContext *cx, JS::HandleObject proxy, JS::MutableHandleIdVector props) const override
[[Enumerate]]
Definition PyDictProxyHandler.cc:80
PyDictProxyHandler()
Definition PyDictProxyHandler.hh:23
bool ownPropertyKeys(JSContext *cx, JS::HandleObject proxy, JS::MutableHandleIdVector props) const override
[[OwnPropertyKeys]]
Definition PyDictProxyHandler.cc:29
bool getOwnEnumerablePropertyKeys(JSContext *cx, JS::HandleObject proxy, JS::MutableHandleIdVector props) const override
Returns vector of proxy's own keys.
Definition PyDictProxyHandler.cc:93
bool defineProperty(JSContext *cx, JS::HandleObject proxy, JS::HandleId id, JS::Handle< JS::PropertyDescriptor > desc, JS::ObjectOpResult &result) const override
Definition PyDictProxyHandler.cc:99
bool set(JSContext *cx, JS::HandleObject proxy, JS::HandleId id, JS::HandleValue v, JS::HandleValue receiver, JS::ObjectOpResult &result) const override
[[Set]]
Definition PyDictProxyHandler.cc:64
bool getBuiltinClass(JSContext *cx, JS::HandleObject proxy, js::ESClass *cls) const override
Definition PyDictProxyHandler.cc:107
static const char family
Definition PyDictProxyHandler.hh:24
bool has(JSContext *cx, JS::HandleObject proxy, JS::HandleId id, bool *bp) const override
[[HasProperty]]
Definition PyDictProxyHandler.cc:48
bool hasOwn(JSContext *cx, JS::HandleObject proxy, JS::HandleId id, bool *bp) const override
Returns true if id is in proxy, false otherwise.
Definition PyDictProxyHandler.cc:85
bool delete_(JSContext *cx, JS::HandleObject proxy, JS::HandleId id, JS::ObjectOpResult &result) const override
[[Delete]]
Definition PyDictProxyHandler.cc:38
This struct is the ProxyHandler for JS Proxy Objects pythonmonkey creates to handle coercion from pyt...
Definition PyObjectProxyHandler.hh:24