WebCore/generated/JSHTMLBlockquoteElement.cpp
changeset 0 4f2f89ce4247
equal deleted inserted replaced
-1:000000000000 0:4f2f89ce4247
       
     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 #include "config.h"
       
    22 #include "JSHTMLBlockquoteElement.h"
       
    23 
       
    24 #include "HTMLBlockquoteElement.h"
       
    25 #include "HTMLNames.h"
       
    26 #include "KURL.h"
       
    27 #include <runtime/JSString.h>
       
    28 #include <wtf/GetPtr.h>
       
    29 
       
    30 using namespace JSC;
       
    31 
       
    32 namespace WebCore {
       
    33 
       
    34 ASSERT_CLASS_FITS_IN_CELL(JSHTMLBlockquoteElement);
       
    35 
       
    36 /* Hash table */
       
    37 #if ENABLE(JIT)
       
    38 #define THUNK_GENERATOR(generator) , generator
       
    39 #else
       
    40 #define THUNK_GENERATOR(generator)
       
    41 #endif
       
    42 
       
    43 static const HashTableValue JSHTMLBlockquoteElementTableValues[3] =
       
    44 {
       
    45     { "cite", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLBlockquoteElementCite), (intptr_t)setJSHTMLBlockquoteElementCite THUNK_GENERATOR(0) },
       
    46     { "constructor", DontEnum | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLBlockquoteElementConstructor), (intptr_t)0 THUNK_GENERATOR(0) },
       
    47     { 0, 0, 0, 0 THUNK_GENERATOR(0) }
       
    48 };
       
    49 
       
    50 #undef THUNK_GENERATOR
       
    51 static JSC_CONST_HASHTABLE HashTable JSHTMLBlockquoteElementTable = { 5, 3, JSHTMLBlockquoteElementTableValues, 0 };
       
    52 /* Hash table for constructor */
       
    53 #if ENABLE(JIT)
       
    54 #define THUNK_GENERATOR(generator) , generator
       
    55 #else
       
    56 #define THUNK_GENERATOR(generator)
       
    57 #endif
       
    58 
       
    59 static const HashTableValue JSHTMLBlockquoteElementConstructorTableValues[1] =
       
    60 {
       
    61     { 0, 0, 0, 0 THUNK_GENERATOR(0) }
       
    62 };
       
    63 
       
    64 #undef THUNK_GENERATOR
       
    65 static JSC_CONST_HASHTABLE HashTable JSHTMLBlockquoteElementConstructorTable = { 1, 0, JSHTMLBlockquoteElementConstructorTableValues, 0 };
       
    66 class JSHTMLBlockquoteElementConstructor : public DOMConstructorObject {
       
    67 public:
       
    68     JSHTMLBlockquoteElementConstructor(JSC::ExecState*, JSDOMGlobalObject*);
       
    69 
       
    70     virtual bool getOwnPropertySlot(JSC::ExecState*, const JSC::Identifier&, JSC::PropertySlot&);
       
    71     virtual bool getOwnPropertyDescriptor(JSC::ExecState*, const JSC::Identifier&, JSC::PropertyDescriptor&);
       
    72     virtual const JSC::ClassInfo* classInfo() const { return &s_info; }
       
    73     static const JSC::ClassInfo s_info;
       
    74     static PassRefPtr<JSC::Structure> createStructure(JSC::JSValue prototype)
       
    75     {
       
    76         return JSC::Structure::create(prototype, JSC::TypeInfo(JSC::ObjectType, StructureFlags), AnonymousSlotCount);
       
    77     }
       
    78 protected:
       
    79     static const unsigned StructureFlags = JSC::OverridesGetOwnPropertySlot | JSC::ImplementsHasInstance | DOMConstructorObject::StructureFlags;
       
    80 };
       
    81 
       
    82 const ClassInfo JSHTMLBlockquoteElementConstructor::s_info = { "HTMLBlockquoteElementConstructor", 0, &JSHTMLBlockquoteElementConstructorTable, 0 };
       
    83 
       
    84 JSHTMLBlockquoteElementConstructor::JSHTMLBlockquoteElementConstructor(ExecState* exec, JSDOMGlobalObject* globalObject)
       
    85     : DOMConstructorObject(JSHTMLBlockquoteElementConstructor::createStructure(globalObject->objectPrototype()), globalObject)
       
    86 {
       
    87     putDirect(exec->propertyNames().prototype, JSHTMLBlockquoteElementPrototype::self(exec, globalObject), DontDelete | ReadOnly);
       
    88 }
       
    89 
       
    90 bool JSHTMLBlockquoteElementConstructor::getOwnPropertySlot(ExecState* exec, const Identifier& propertyName, PropertySlot& slot)
       
    91 {
       
    92     return getStaticValueSlot<JSHTMLBlockquoteElementConstructor, DOMObject>(exec, &JSHTMLBlockquoteElementConstructorTable, this, propertyName, slot);
       
    93 }
       
    94 
       
    95 bool JSHTMLBlockquoteElementConstructor::getOwnPropertyDescriptor(ExecState* exec, const Identifier& propertyName, PropertyDescriptor& descriptor)
       
    96 {
       
    97     return getStaticValueDescriptor<JSHTMLBlockquoteElementConstructor, DOMObject>(exec, &JSHTMLBlockquoteElementConstructorTable, this, propertyName, descriptor);
       
    98 }
       
    99 
       
   100 /* Hash table for prototype */
       
   101 #if ENABLE(JIT)
       
   102 #define THUNK_GENERATOR(generator) , generator
       
   103 #else
       
   104 #define THUNK_GENERATOR(generator)
       
   105 #endif
       
   106 
       
   107 static const HashTableValue JSHTMLBlockquoteElementPrototypeTableValues[1] =
       
   108 {
       
   109     { 0, 0, 0, 0 THUNK_GENERATOR(0) }
       
   110 };
       
   111 
       
   112 #undef THUNK_GENERATOR
       
   113 static JSC_CONST_HASHTABLE HashTable JSHTMLBlockquoteElementPrototypeTable = { 1, 0, JSHTMLBlockquoteElementPrototypeTableValues, 0 };
       
   114 const ClassInfo JSHTMLBlockquoteElementPrototype::s_info = { "HTMLBlockquoteElementPrototype", 0, &JSHTMLBlockquoteElementPrototypeTable, 0 };
       
   115 
       
   116 JSObject* JSHTMLBlockquoteElementPrototype::self(ExecState* exec, JSGlobalObject* globalObject)
       
   117 {
       
   118     return getDOMPrototype<JSHTMLBlockquoteElement>(exec, globalObject);
       
   119 }
       
   120 
       
   121 const ClassInfo JSHTMLBlockquoteElement::s_info = { "HTMLBlockquoteElement", &JSHTMLElement::s_info, &JSHTMLBlockquoteElementTable, 0 };
       
   122 
       
   123 JSHTMLBlockquoteElement::JSHTMLBlockquoteElement(NonNullPassRefPtr<Structure> structure, JSDOMGlobalObject* globalObject, PassRefPtr<HTMLBlockquoteElement> impl)
       
   124     : JSHTMLElement(structure, globalObject, impl)
       
   125 {
       
   126 }
       
   127 
       
   128 JSObject* JSHTMLBlockquoteElement::createPrototype(ExecState* exec, JSGlobalObject* globalObject)
       
   129 {
       
   130     return new (exec) JSHTMLBlockquoteElementPrototype(globalObject, JSHTMLBlockquoteElementPrototype::createStructure(JSHTMLElementPrototype::self(exec, globalObject)));
       
   131 }
       
   132 
       
   133 bool JSHTMLBlockquoteElement::getOwnPropertySlot(ExecState* exec, const Identifier& propertyName, PropertySlot& slot)
       
   134 {
       
   135     return getStaticValueSlot<JSHTMLBlockquoteElement, Base>(exec, &JSHTMLBlockquoteElementTable, this, propertyName, slot);
       
   136 }
       
   137 
       
   138 bool JSHTMLBlockquoteElement::getOwnPropertyDescriptor(ExecState* exec, const Identifier& propertyName, PropertyDescriptor& descriptor)
       
   139 {
       
   140     return getStaticValueDescriptor<JSHTMLBlockquoteElement, Base>(exec, &JSHTMLBlockquoteElementTable, this, propertyName, descriptor);
       
   141 }
       
   142 
       
   143 JSValue jsHTMLBlockquoteElementCite(ExecState* exec, JSValue slotBase, const Identifier&)
       
   144 {
       
   145     JSHTMLBlockquoteElement* castedThis = static_cast<JSHTMLBlockquoteElement*>(asObject(slotBase));
       
   146     UNUSED_PARAM(exec);
       
   147     HTMLBlockquoteElement* imp = static_cast<HTMLBlockquoteElement*>(castedThis->impl());
       
   148     JSValue result = jsString(exec, imp->getAttribute(WebCore::HTMLNames::citeAttr));
       
   149     return result;
       
   150 }
       
   151 
       
   152 JSValue jsHTMLBlockquoteElementConstructor(ExecState* exec, JSValue slotBase, const Identifier&)
       
   153 {
       
   154     JSHTMLBlockquoteElement* domObject = static_cast<JSHTMLBlockquoteElement*>(asObject(slotBase));
       
   155     return JSHTMLBlockquoteElement::getConstructor(exec, domObject->globalObject());
       
   156 }
       
   157 void JSHTMLBlockquoteElement::put(ExecState* exec, const Identifier& propertyName, JSValue value, PutPropertySlot& slot)
       
   158 {
       
   159     lookupPut<JSHTMLBlockquoteElement, Base>(exec, propertyName, value, &JSHTMLBlockquoteElementTable, this, slot);
       
   160 }
       
   161 
       
   162 void setJSHTMLBlockquoteElementCite(ExecState* exec, JSObject* thisObject, JSValue value)
       
   163 {
       
   164     JSHTMLBlockquoteElement* castedThis = static_cast<JSHTMLBlockquoteElement*>(thisObject);
       
   165     HTMLBlockquoteElement* imp = static_cast<HTMLBlockquoteElement*>(castedThis->impl());
       
   166     imp->setAttribute(WebCore::HTMLNames::citeAttr, valueToStringWithNullCheck(exec, value));
       
   167 }
       
   168 
       
   169 JSValue JSHTMLBlockquoteElement::getConstructor(ExecState* exec, JSGlobalObject* globalObject)
       
   170 {
       
   171     return getDOMConstructor<JSHTMLBlockquoteElementConstructor>(exec, static_cast<JSDOMGlobalObject*>(globalObject));
       
   172 }
       
   173 
       
   174 
       
   175 }