| 1 | /* |
| 2 | This file is part of the WebKit open source project. |
| 3 | This file has been generated by generate-bindings.pl. DO NOT MODIFY! |
| 4 | |
| 5 | This library is free software; you can redistribute it and/or |
| 6 | modify it under the terms of the GNU Library General Public |
| 7 | License as published by the Free Software Foundation; either |
| 8 | version 2 of the License, or (at your option) any later version. |
| 9 | |
| 10 | This library is distributed in the hope that it will be useful, |
| 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 13 | Library General Public License for more details. |
| 14 | |
| 15 | You should have received a copy of the GNU Library General Public License |
| 16 | along with this library; see the file COPYING.LIB. If not, write to |
| 17 | the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
| 18 | Boston, MA 02110-1301, USA. |
| 19 | */ |
| 20 | |
| 21 | #pragma once |
| 22 | |
| 23 | #include "JSDOMWrapper.h" |
| 24 | #include "JSRemoteDOMWindowBase.h" |
| 25 | |
| 26 | namespace WebCore { |
| 27 | |
| 28 | class RemoteDOMWindow; |
| 29 | |
| 30 | class JSWindowProxy; |
| 31 | |
| 32 | class JSRemoteDOMWindow : public JSRemoteDOMWindowBase { |
| 33 | public: |
| 34 | using Base = JSRemoteDOMWindowBase; |
| 35 | using DOMWrapped = RemoteDOMWindow; |
| 36 | static JSRemoteDOMWindow* create(JSC::VM& vm, JSC::Structure* structure, Ref<RemoteDOMWindow>&& impl, JSWindowProxy* proxy) |
| 37 | { |
| 38 | JSRemoteDOMWindow* ptr = new (NotNull, JSC::allocateCell<JSRemoteDOMWindow>(vm.heap)) JSRemoteDOMWindow(vm, structure, WTFMove(impl), proxy); |
| 39 | ptr->finishCreation(vm, proxy); |
| 40 | return ptr; |
| 41 | } |
| 42 | |
| 43 | static const bool needsDestruction = false; |
| 44 | |
| 45 | static bool getOwnPropertySlot(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&); |
| 46 | static bool getOwnPropertySlotByIndex(JSC::JSObject*, JSC::ExecState*, unsigned propertyName, JSC::PropertySlot&); |
| 47 | static void getOwnPropertyNames(JSC::JSObject*, JSC::ExecState*, JSC::PropertyNameArray&, JSC::EnumerationMode = JSC::EnumerationMode()); |
| 48 | static bool put(JSC::JSCell*, JSC::ExecState*, JSC::PropertyName, JSC::JSValue, JSC::PutPropertySlot&); |
| 49 | static bool putByIndex(JSC::JSCell*, JSC::ExecState*, unsigned propertyName, JSC::JSValue, bool shouldThrow); |
| 50 | static bool defineOwnProperty(JSC::JSObject*, JSC::ExecState*, JSC::PropertyName, const JSC::PropertyDescriptor&, bool shouldThrow); |
| 51 | static bool deleteProperty(JSC::JSCell*, JSC::ExecState*, JSC::PropertyName); |
| 52 | static bool deletePropertyByIndex(JSC::JSCell*, JSC::ExecState*, unsigned); |
| 53 | static JSC::JSValue getPrototype(JSC::JSObject*, JSC::ExecState*); |
| 54 | static String toStringName(const JSC::JSObject*, JSC::ExecState*); |
| 55 | static bool preventExtensions(JSC::JSObject*, JSC::ExecState*); |
| 56 | |
| 57 | DECLARE_INFO; |
| 58 | |
| 59 | static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype) |
| 60 | { |
| 61 | return JSC::Structure::create(vm, globalObject, prototype, JSC::TypeInfo(JSC::GlobalObjectType, StructureFlags), info()); |
| 62 | } |
| 63 | |
| 64 | static void heapSnapshot(JSCell*, JSC::HeapSnapshotBuilder&); |
| 65 | RemoteDOMWindow& wrapped() const |
| 66 | { |
| 67 | return static_cast<RemoteDOMWindow&>(Base::wrapped()); |
| 68 | } |
| 69 | public: |
| 70 | static const unsigned StructureFlags = Base::StructureFlags | JSC::HasStaticPropertyTable | JSC::InterceptsGetOwnPropertySlotByIndexEvenWhenLengthIsNotZero | JSC::IsImmutablePrototypeExoticObject | JSC::OverridesGetOwnPropertySlot | JSC::OverridesGetPropertyNames; |
| 71 | protected: |
| 72 | JSRemoteDOMWindow(JSC::VM&, JSC::Structure*, Ref<RemoteDOMWindow>&&, JSWindowProxy*); |
| 73 | void finishCreation(JSC::VM&, JSWindowProxy*); |
| 74 | }; |
| 75 | |
| 76 | |
| 77 | class JSRemoteDOMWindowPrototype : public JSC::JSNonFinalObject { |
| 78 | public: |
| 79 | using Base = JSC::JSNonFinalObject; |
| 80 | static JSRemoteDOMWindowPrototype* create(JSC::VM& vm, JSDOMGlobalObject* globalObject, JSC::Structure* structure) |
| 81 | { |
| 82 | JSRemoteDOMWindowPrototype* ptr = new (NotNull, JSC::allocateCell<JSRemoteDOMWindowPrototype>(vm.heap)) JSRemoteDOMWindowPrototype(vm, globalObject, structure); |
| 83 | ptr->finishCreation(vm); |
| 84 | return ptr; |
| 85 | } |
| 86 | |
| 87 | DECLARE_INFO; |
| 88 | static JSC::Structure* createStructure(JSC::VM& vm, JSC::JSGlobalObject* globalObject, JSC::JSValue prototype) |
| 89 | { |
| 90 | return JSC::Structure::create(vm, globalObject, prototype, JSC::TypeInfo(JSC::ObjectType, StructureFlags), info()); |
| 91 | } |
| 92 | |
| 93 | private: |
| 94 | JSRemoteDOMWindowPrototype(JSC::VM& vm, JSC::JSGlobalObject*, JSC::Structure* structure) |
| 95 | : JSC::JSNonFinalObject(vm, structure) |
| 96 | { |
| 97 | } |
| 98 | public: |
| 99 | static const unsigned StructureFlags = Base::StructureFlags | JSC::IsImmutablePrototypeExoticObject; |
| 100 | }; |
| 101 | |
| 102 | // Functions |
| 103 | |
| 104 | JSC::EncodedJSValue JSC_HOST_CALL jsRemoteDOMWindowInstanceFunctionClose(JSC::ExecState*); |
| 105 | JSC::EncodedJSValue JSC_HOST_CALL jsRemoteDOMWindowInstanceFunctionFocus(JSC::ExecState*); |
| 106 | JSC::EncodedJSValue JSC_HOST_CALL jsRemoteDOMWindowInstanceFunctionBlur(JSC::ExecState*); |
| 107 | JSC::EncodedJSValue JSC_HOST_CALL jsRemoteDOMWindowInstanceFunctionPostMessage(JSC::ExecState*); |
| 108 | |
| 109 | // Attributes |
| 110 | |
| 111 | JSC::EncodedJSValue jsRemoteDOMWindowClosed(JSC::ExecState*, JSC::EncodedJSValue, JSC::PropertyName); |
| 112 | template<> struct JSDOMWrapperConverterTraits<RemoteDOMWindow> { |
| 113 | using WrapperClass = JSRemoteDOMWindow; |
| 114 | using ToWrappedReturnType = RemoteDOMWindow*; |
| 115 | }; |
| 116 | |
| 117 | } // namespace WebCore |
| 118 | |