1 // Copyright 2015 Samsung Electronics Co, Ltd. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef WRT_OBJECT_TOOLS_MODULE_H_
6 #define WRT_OBJECT_TOOLS_MODULE_H_
8 #include <JavaScriptCore/JavaScript.h>
10 #include "xwalk_module_system.h"
14 // This module provides extra JS functions that help writing JS API code for
15 // extensions, for example: allowing setting a read-only property of an object.
16 class ObjectToolsModule : public NativeModule {
18 ObjectToolsModule(JSContextRef context);
22 JSObjectRef NewInstance(JSContextRef context);
24 JSObjectRef object_function_;
25 JSContextRef js_context_;
30 #endif // WRT_OBJECT_TOOLS_MODULE_H_