WebCore/generated/JSHTMLTableElement.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 "JSHTMLTableElement.h"
       
    23 
       
    24 #include "HTMLCollection.h"
       
    25 #include "HTMLElement.h"
       
    26 #include "HTMLNames.h"
       
    27 #include "HTMLTableCaptionElement.h"
       
    28 #include "HTMLTableElement.h"
       
    29 #include "HTMLTableSectionElement.h"
       
    30 #include "JSHTMLCollection.h"
       
    31 #include "JSHTMLElement.h"
       
    32 #include "JSHTMLTableCaptionElement.h"
       
    33 #include "JSHTMLTableSectionElement.h"
       
    34 #include "KURL.h"
       
    35 #include <runtime/Error.h>
       
    36 #include <runtime/JSString.h>
       
    37 #include <wtf/GetPtr.h>
       
    38 
       
    39 using namespace JSC;
       
    40 
       
    41 namespace WebCore {
       
    42 
       
    43 ASSERT_CLASS_FITS_IN_CELL(JSHTMLTableElement);
       
    44 
       
    45 /* Hash table */
       
    46 #if ENABLE(JIT)
       
    47 #define THUNK_GENERATOR(generator) , generator
       
    48 #else
       
    49 #define THUNK_GENERATOR(generator)
       
    50 #endif
       
    51 
       
    52 static const HashTableValue JSHTMLTableElementTableValues[16] =
       
    53 {
       
    54     { "caption", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementCaption), (intptr_t)setJSHTMLTableElementCaption THUNK_GENERATOR(0) },
       
    55     { "tHead", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementTHead), (intptr_t)setJSHTMLTableElementTHead THUNK_GENERATOR(0) },
       
    56     { "tFoot", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementTFoot), (intptr_t)setJSHTMLTableElementTFoot THUNK_GENERATOR(0) },
       
    57     { "rows", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementRows), (intptr_t)0 THUNK_GENERATOR(0) },
       
    58     { "tBodies", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementTBodies), (intptr_t)0 THUNK_GENERATOR(0) },
       
    59     { "align", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementAlign), (intptr_t)setJSHTMLTableElementAlign THUNK_GENERATOR(0) },
       
    60     { "bgColor", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementBgColor), (intptr_t)setJSHTMLTableElementBgColor THUNK_GENERATOR(0) },
       
    61     { "border", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementBorder), (intptr_t)setJSHTMLTableElementBorder THUNK_GENERATOR(0) },
       
    62     { "cellPadding", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementCellPadding), (intptr_t)setJSHTMLTableElementCellPadding THUNK_GENERATOR(0) },
       
    63     { "cellSpacing", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementCellSpacing), (intptr_t)setJSHTMLTableElementCellSpacing THUNK_GENERATOR(0) },
       
    64     { "frame", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementFrame), (intptr_t)setJSHTMLTableElementFrame THUNK_GENERATOR(0) },
       
    65     { "rules", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementRules), (intptr_t)setJSHTMLTableElementRules THUNK_GENERATOR(0) },
       
    66     { "summary", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementSummary), (intptr_t)setJSHTMLTableElementSummary THUNK_GENERATOR(0) },
       
    67     { "width", DontDelete, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementWidth), (intptr_t)setJSHTMLTableElementWidth THUNK_GENERATOR(0) },
       
    68     { "constructor", DontEnum | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsHTMLTableElementConstructor), (intptr_t)0 THUNK_GENERATOR(0) },
       
    69     { 0, 0, 0, 0 THUNK_GENERATOR(0) }
       
    70 };
       
    71 
       
    72 #undef THUNK_GENERATOR
       
    73 static JSC_CONST_HASHTABLE HashTable JSHTMLTableElementTable = { 35, 31, JSHTMLTableElementTableValues, 0 };
       
    74 /* Hash table for constructor */
       
    75 #if ENABLE(JIT)
       
    76 #define THUNK_GENERATOR(generator) , generator
       
    77 #else
       
    78 #define THUNK_GENERATOR(generator)
       
    79 #endif
       
    80 
       
    81 static const HashTableValue JSHTMLTableElementConstructorTableValues[1] =
       
    82 {
       
    83     { 0, 0, 0, 0 THUNK_GENERATOR(0) }
       
    84 };
       
    85 
       
    86 #undef THUNK_GENERATOR
       
    87 static JSC_CONST_HASHTABLE HashTable JSHTMLTableElementConstructorTable = { 1, 0, JSHTMLTableElementConstructorTableValues, 0 };
       
    88 class JSHTMLTableElementConstructor : public DOMConstructorObject {
       
    89 public:
       
    90     JSHTMLTableElementConstructor(JSC::ExecState*, JSDOMGlobalObject*);
       
    91 
       
    92     virtual bool getOwnPropertySlot(JSC::ExecState*, const JSC::Identifier&, JSC::PropertySlot&);
       
    93     virtual bool getOwnPropertyDescriptor(JSC::ExecState*, const JSC::Identifier&, JSC::PropertyDescriptor&);
       
    94     virtual const JSC::ClassInfo* classInfo() const { return &s_info; }
       
    95     static const JSC::ClassInfo s_info;
       
    96     static PassRefPtr<JSC::Structure> createStructure(JSC::JSValue prototype)
       
    97     {
       
    98         return JSC::Structure::create(prototype, JSC::TypeInfo(JSC::ObjectType, StructureFlags), AnonymousSlotCount);
       
    99     }
       
   100 protected:
       
   101     static const unsigned StructureFlags = JSC::OverridesGetOwnPropertySlot | JSC::ImplementsHasInstance | DOMConstructorObject::StructureFlags;
       
   102 };
       
   103 
       
   104 const ClassInfo JSHTMLTableElementConstructor::s_info = { "HTMLTableElementConstructor", 0, &JSHTMLTableElementConstructorTable, 0 };
       
   105 
       
   106 JSHTMLTableElementConstructor::JSHTMLTableElementConstructor(ExecState* exec, JSDOMGlobalObject* globalObject)
       
   107     : DOMConstructorObject(JSHTMLTableElementConstructor::createStructure(globalObject->objectPrototype()), globalObject)
       
   108 {
       
   109     putDirect(exec->propertyNames().prototype, JSHTMLTableElementPrototype::self(exec, globalObject), DontDelete | ReadOnly);
       
   110 }
       
   111 
       
   112 bool JSHTMLTableElementConstructor::getOwnPropertySlot(ExecState* exec, const Identifier& propertyName, PropertySlot& slot)
       
   113 {
       
   114     return getStaticValueSlot<JSHTMLTableElementConstructor, DOMObject>(exec, &JSHTMLTableElementConstructorTable, this, propertyName, slot);
       
   115 }
       
   116 
       
   117 bool JSHTMLTableElementConstructor::getOwnPropertyDescriptor(ExecState* exec, const Identifier& propertyName, PropertyDescriptor& descriptor)
       
   118 {
       
   119     return getStaticValueDescriptor<JSHTMLTableElementConstructor, DOMObject>(exec, &JSHTMLTableElementConstructorTable, this, propertyName, descriptor);
       
   120 }
       
   121 
       
   122 /* Hash table for prototype */
       
   123 #if ENABLE(JIT)
       
   124 #define THUNK_GENERATOR(generator) , generator
       
   125 #else
       
   126 #define THUNK_GENERATOR(generator)
       
   127 #endif
       
   128 
       
   129 static const HashTableValue JSHTMLTableElementPrototypeTableValues[9] =
       
   130 {
       
   131     { "createTHead", DontDelete | Function, (intptr_t)static_cast<NativeFunction>(jsHTMLTableElementPrototypeFunctionCreateTHead), (intptr_t)0 THUNK_GENERATOR(0) },
       
   132     { "deleteTHead", DontDelete | Function, (intptr_t)static_cast<NativeFunction>(jsHTMLTableElementPrototypeFunctionDeleteTHead), (intptr_t)0 THUNK_GENERATOR(0) },
       
   133     { "createTFoot", DontDelete | Function, (intptr_t)static_cast<NativeFunction>(jsHTMLTableElementPrototypeFunctionCreateTFoot), (intptr_t)0 THUNK_GENERATOR(0) },
       
   134     { "deleteTFoot", DontDelete | Function, (intptr_t)static_cast<NativeFunction>(jsHTMLTableElementPrototypeFunctionDeleteTFoot), (intptr_t)0 THUNK_GENERATOR(0) },
       
   135     { "createCaption", DontDelete | Function, (intptr_t)static_cast<NativeFunction>(jsHTMLTableElementPrototypeFunctionCreateCaption), (intptr_t)0 THUNK_GENERATOR(0) },
       
   136     { "deleteCaption", DontDelete | Function, (intptr_t)static_cast<NativeFunction>(jsHTMLTableElementPrototypeFunctionDeleteCaption), (intptr_t)0 THUNK_GENERATOR(0) },
       
   137     { "insertRow", DontDelete | Function, (intptr_t)static_cast<NativeFunction>(jsHTMLTableElementPrototypeFunctionInsertRow), (intptr_t)1 THUNK_GENERATOR(0) },
       
   138     { "deleteRow", DontDelete | Function, (intptr_t)static_cast<NativeFunction>(jsHTMLTableElementPrototypeFunctionDeleteRow), (intptr_t)1 THUNK_GENERATOR(0) },
       
   139     { 0, 0, 0, 0 THUNK_GENERATOR(0) }
       
   140 };
       
   141 
       
   142 #undef THUNK_GENERATOR
       
   143 static JSC_CONST_HASHTABLE HashTable JSHTMLTableElementPrototypeTable = { 19, 15, JSHTMLTableElementPrototypeTableValues, 0 };
       
   144 const ClassInfo JSHTMLTableElementPrototype::s_info = { "HTMLTableElementPrototype", 0, &JSHTMLTableElementPrototypeTable, 0 };
       
   145 
       
   146 JSObject* JSHTMLTableElementPrototype::self(ExecState* exec, JSGlobalObject* globalObject)
       
   147 {
       
   148     return getDOMPrototype<JSHTMLTableElement>(exec, globalObject);
       
   149 }
       
   150 
       
   151 bool JSHTMLTableElementPrototype::getOwnPropertySlot(ExecState* exec, const Identifier& propertyName, PropertySlot& slot)
       
   152 {
       
   153     return getStaticFunctionSlot<JSObject>(exec, &JSHTMLTableElementPrototypeTable, this, propertyName, slot);
       
   154 }
       
   155 
       
   156 bool JSHTMLTableElementPrototype::getOwnPropertyDescriptor(ExecState* exec, const Identifier& propertyName, PropertyDescriptor& descriptor)
       
   157 {
       
   158     return getStaticFunctionDescriptor<JSObject>(exec, &JSHTMLTableElementPrototypeTable, this, propertyName, descriptor);
       
   159 }
       
   160 
       
   161 const ClassInfo JSHTMLTableElement::s_info = { "HTMLTableElement", &JSHTMLElement::s_info, &JSHTMLTableElementTable, 0 };
       
   162 
       
   163 JSHTMLTableElement::JSHTMLTableElement(NonNullPassRefPtr<Structure> structure, JSDOMGlobalObject* globalObject, PassRefPtr<HTMLTableElement> impl)
       
   164     : JSHTMLElement(structure, globalObject, impl)
       
   165 {
       
   166 }
       
   167 
       
   168 JSObject* JSHTMLTableElement::createPrototype(ExecState* exec, JSGlobalObject* globalObject)
       
   169 {
       
   170     return new (exec) JSHTMLTableElementPrototype(globalObject, JSHTMLTableElementPrototype::createStructure(JSHTMLElementPrototype::self(exec, globalObject)));
       
   171 }
       
   172 
       
   173 bool JSHTMLTableElement::getOwnPropertySlot(ExecState* exec, const Identifier& propertyName, PropertySlot& slot)
       
   174 {
       
   175     return getStaticValueSlot<JSHTMLTableElement, Base>(exec, &JSHTMLTableElementTable, this, propertyName, slot);
       
   176 }
       
   177 
       
   178 bool JSHTMLTableElement::getOwnPropertyDescriptor(ExecState* exec, const Identifier& propertyName, PropertyDescriptor& descriptor)
       
   179 {
       
   180     return getStaticValueDescriptor<JSHTMLTableElement, Base>(exec, &JSHTMLTableElementTable, this, propertyName, descriptor);
       
   181 }
       
   182 
       
   183 JSValue jsHTMLTableElementCaption(ExecState* exec, JSValue slotBase, const Identifier&)
       
   184 {
       
   185     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   186     UNUSED_PARAM(exec);
       
   187     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   188     JSValue result = toJS(exec, castedThis->globalObject(), WTF::getPtr(imp->caption()));
       
   189     return result;
       
   190 }
       
   191 
       
   192 JSValue jsHTMLTableElementTHead(ExecState* exec, JSValue slotBase, const Identifier&)
       
   193 {
       
   194     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   195     UNUSED_PARAM(exec);
       
   196     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   197     JSValue result = toJS(exec, castedThis->globalObject(), WTF::getPtr(imp->tHead()));
       
   198     return result;
       
   199 }
       
   200 
       
   201 JSValue jsHTMLTableElementTFoot(ExecState* exec, JSValue slotBase, const Identifier&)
       
   202 {
       
   203     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   204     UNUSED_PARAM(exec);
       
   205     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   206     JSValue result = toJS(exec, castedThis->globalObject(), WTF::getPtr(imp->tFoot()));
       
   207     return result;
       
   208 }
       
   209 
       
   210 JSValue jsHTMLTableElementRows(ExecState* exec, JSValue slotBase, const Identifier&)
       
   211 {
       
   212     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   213     UNUSED_PARAM(exec);
       
   214     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   215     JSValue result = toJS(exec, castedThis->globalObject(), WTF::getPtr(imp->rows()));
       
   216     return result;
       
   217 }
       
   218 
       
   219 JSValue jsHTMLTableElementTBodies(ExecState* exec, JSValue slotBase, const Identifier&)
       
   220 {
       
   221     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   222     UNUSED_PARAM(exec);
       
   223     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   224     JSValue result = toJS(exec, castedThis->globalObject(), WTF::getPtr(imp->tBodies()));
       
   225     return result;
       
   226 }
       
   227 
       
   228 JSValue jsHTMLTableElementAlign(ExecState* exec, JSValue slotBase, const Identifier&)
       
   229 {
       
   230     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   231     UNUSED_PARAM(exec);
       
   232     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   233     JSValue result = jsString(exec, imp->getAttribute(WebCore::HTMLNames::alignAttr));
       
   234     return result;
       
   235 }
       
   236 
       
   237 JSValue jsHTMLTableElementBgColor(ExecState* exec, JSValue slotBase, const Identifier&)
       
   238 {
       
   239     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   240     UNUSED_PARAM(exec);
       
   241     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   242     JSValue result = jsString(exec, imp->getAttribute(WebCore::HTMLNames::bgcolorAttr));
       
   243     return result;
       
   244 }
       
   245 
       
   246 JSValue jsHTMLTableElementBorder(ExecState* exec, JSValue slotBase, const Identifier&)
       
   247 {
       
   248     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   249     UNUSED_PARAM(exec);
       
   250     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   251     JSValue result = jsString(exec, imp->getAttribute(WebCore::HTMLNames::borderAttr));
       
   252     return result;
       
   253 }
       
   254 
       
   255 JSValue jsHTMLTableElementCellPadding(ExecState* exec, JSValue slotBase, const Identifier&)
       
   256 {
       
   257     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   258     UNUSED_PARAM(exec);
       
   259     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   260     JSValue result = jsString(exec, imp->getAttribute(WebCore::HTMLNames::cellpaddingAttr));
       
   261     return result;
       
   262 }
       
   263 
       
   264 JSValue jsHTMLTableElementCellSpacing(ExecState* exec, JSValue slotBase, const Identifier&)
       
   265 {
       
   266     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   267     UNUSED_PARAM(exec);
       
   268     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   269     JSValue result = jsString(exec, imp->getAttribute(WebCore::HTMLNames::cellspacingAttr));
       
   270     return result;
       
   271 }
       
   272 
       
   273 JSValue jsHTMLTableElementFrame(ExecState* exec, JSValue slotBase, const Identifier&)
       
   274 {
       
   275     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   276     UNUSED_PARAM(exec);
       
   277     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   278     JSValue result = jsString(exec, imp->getAttribute(WebCore::HTMLNames::frameAttr));
       
   279     return result;
       
   280 }
       
   281 
       
   282 JSValue jsHTMLTableElementRules(ExecState* exec, JSValue slotBase, const Identifier&)
       
   283 {
       
   284     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   285     UNUSED_PARAM(exec);
       
   286     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   287     JSValue result = jsString(exec, imp->getAttribute(WebCore::HTMLNames::rulesAttr));
       
   288     return result;
       
   289 }
       
   290 
       
   291 JSValue jsHTMLTableElementSummary(ExecState* exec, JSValue slotBase, const Identifier&)
       
   292 {
       
   293     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   294     UNUSED_PARAM(exec);
       
   295     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   296     JSValue result = jsString(exec, imp->getAttribute(WebCore::HTMLNames::summaryAttr));
       
   297     return result;
       
   298 }
       
   299 
       
   300 JSValue jsHTMLTableElementWidth(ExecState* exec, JSValue slotBase, const Identifier&)
       
   301 {
       
   302     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   303     UNUSED_PARAM(exec);
       
   304     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   305     JSValue result = jsString(exec, imp->getAttribute(WebCore::HTMLNames::widthAttr));
       
   306     return result;
       
   307 }
       
   308 
       
   309 JSValue jsHTMLTableElementConstructor(ExecState* exec, JSValue slotBase, const Identifier&)
       
   310 {
       
   311     JSHTMLTableElement* domObject = static_cast<JSHTMLTableElement*>(asObject(slotBase));
       
   312     return JSHTMLTableElement::getConstructor(exec, domObject->globalObject());
       
   313 }
       
   314 void JSHTMLTableElement::put(ExecState* exec, const Identifier& propertyName, JSValue value, PutPropertySlot& slot)
       
   315 {
       
   316     lookupPut<JSHTMLTableElement, Base>(exec, propertyName, value, &JSHTMLTableElementTable, this, slot);
       
   317 }
       
   318 
       
   319 void setJSHTMLTableElementCaption(ExecState* exec, JSObject* thisObject, JSValue value)
       
   320 {
       
   321     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(thisObject);
       
   322     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   323     ExceptionCode ec = 0;
       
   324     imp->setCaption(toHTMLTableCaptionElement(value), ec);
       
   325     setDOMException(exec, ec);
       
   326 }
       
   327 
       
   328 void setJSHTMLTableElementTHead(ExecState* exec, JSObject* thisObject, JSValue value)
       
   329 {
       
   330     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(thisObject);
       
   331     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   332     ExceptionCode ec = 0;
       
   333     imp->setTHead(toHTMLTableSectionElement(value), ec);
       
   334     setDOMException(exec, ec);
       
   335 }
       
   336 
       
   337 void setJSHTMLTableElementTFoot(ExecState* exec, JSObject* thisObject, JSValue value)
       
   338 {
       
   339     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(thisObject);
       
   340     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   341     ExceptionCode ec = 0;
       
   342     imp->setTFoot(toHTMLTableSectionElement(value), ec);
       
   343     setDOMException(exec, ec);
       
   344 }
       
   345 
       
   346 void setJSHTMLTableElementAlign(ExecState* exec, JSObject* thisObject, JSValue value)
       
   347 {
       
   348     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(thisObject);
       
   349     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   350     imp->setAttribute(WebCore::HTMLNames::alignAttr, valueToStringWithNullCheck(exec, value));
       
   351 }
       
   352 
       
   353 void setJSHTMLTableElementBgColor(ExecState* exec, JSObject* thisObject, JSValue value)
       
   354 {
       
   355     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(thisObject);
       
   356     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   357     imp->setAttribute(WebCore::HTMLNames::bgcolorAttr, valueToStringWithNullCheck(exec, value));
       
   358 }
       
   359 
       
   360 void setJSHTMLTableElementBorder(ExecState* exec, JSObject* thisObject, JSValue value)
       
   361 {
       
   362     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(thisObject);
       
   363     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   364     imp->setAttribute(WebCore::HTMLNames::borderAttr, valueToStringWithNullCheck(exec, value));
       
   365 }
       
   366 
       
   367 void setJSHTMLTableElementCellPadding(ExecState* exec, JSObject* thisObject, JSValue value)
       
   368 {
       
   369     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(thisObject);
       
   370     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   371     imp->setAttribute(WebCore::HTMLNames::cellpaddingAttr, valueToStringWithNullCheck(exec, value));
       
   372 }
       
   373 
       
   374 void setJSHTMLTableElementCellSpacing(ExecState* exec, JSObject* thisObject, JSValue value)
       
   375 {
       
   376     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(thisObject);
       
   377     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   378     imp->setAttribute(WebCore::HTMLNames::cellspacingAttr, valueToStringWithNullCheck(exec, value));
       
   379 }
       
   380 
       
   381 void setJSHTMLTableElementFrame(ExecState* exec, JSObject* thisObject, JSValue value)
       
   382 {
       
   383     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(thisObject);
       
   384     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   385     imp->setAttribute(WebCore::HTMLNames::frameAttr, valueToStringWithNullCheck(exec, value));
       
   386 }
       
   387 
       
   388 void setJSHTMLTableElementRules(ExecState* exec, JSObject* thisObject, JSValue value)
       
   389 {
       
   390     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(thisObject);
       
   391     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   392     imp->setAttribute(WebCore::HTMLNames::rulesAttr, valueToStringWithNullCheck(exec, value));
       
   393 }
       
   394 
       
   395 void setJSHTMLTableElementSummary(ExecState* exec, JSObject* thisObject, JSValue value)
       
   396 {
       
   397     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(thisObject);
       
   398     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   399     imp->setAttribute(WebCore::HTMLNames::summaryAttr, valueToStringWithNullCheck(exec, value));
       
   400 }
       
   401 
       
   402 void setJSHTMLTableElementWidth(ExecState* exec, JSObject* thisObject, JSValue value)
       
   403 {
       
   404     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(thisObject);
       
   405     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   406     imp->setAttribute(WebCore::HTMLNames::widthAttr, valueToStringWithNullCheck(exec, value));
       
   407 }
       
   408 
       
   409 JSValue JSHTMLTableElement::getConstructor(ExecState* exec, JSGlobalObject* globalObject)
       
   410 {
       
   411     return getDOMConstructor<JSHTMLTableElementConstructor>(exec, static_cast<JSDOMGlobalObject*>(globalObject));
       
   412 }
       
   413 
       
   414 EncodedJSValue JSC_HOST_CALL jsHTMLTableElementPrototypeFunctionCreateTHead(ExecState* exec)
       
   415 {
       
   416     JSValue thisValue = exec->hostThisValue();
       
   417     if (!thisValue.inherits(&JSHTMLTableElement::s_info))
       
   418         return throwVMTypeError(exec);
       
   419     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(thisValue));
       
   420     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   421 
       
   422 
       
   423     JSC::JSValue result = toJS(exec, castedThis->globalObject(), WTF::getPtr(imp->createTHead()));
       
   424     return JSValue::encode(result);
       
   425 }
       
   426 
       
   427 EncodedJSValue JSC_HOST_CALL jsHTMLTableElementPrototypeFunctionDeleteTHead(ExecState* exec)
       
   428 {
       
   429     JSValue thisValue = exec->hostThisValue();
       
   430     if (!thisValue.inherits(&JSHTMLTableElement::s_info))
       
   431         return throwVMTypeError(exec);
       
   432     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(thisValue));
       
   433     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   434 
       
   435     imp->deleteTHead();
       
   436     return JSValue::encode(jsUndefined());
       
   437 }
       
   438 
       
   439 EncodedJSValue JSC_HOST_CALL jsHTMLTableElementPrototypeFunctionCreateTFoot(ExecState* exec)
       
   440 {
       
   441     JSValue thisValue = exec->hostThisValue();
       
   442     if (!thisValue.inherits(&JSHTMLTableElement::s_info))
       
   443         return throwVMTypeError(exec);
       
   444     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(thisValue));
       
   445     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   446 
       
   447 
       
   448     JSC::JSValue result = toJS(exec, castedThis->globalObject(), WTF::getPtr(imp->createTFoot()));
       
   449     return JSValue::encode(result);
       
   450 }
       
   451 
       
   452 EncodedJSValue JSC_HOST_CALL jsHTMLTableElementPrototypeFunctionDeleteTFoot(ExecState* exec)
       
   453 {
       
   454     JSValue thisValue = exec->hostThisValue();
       
   455     if (!thisValue.inherits(&JSHTMLTableElement::s_info))
       
   456         return throwVMTypeError(exec);
       
   457     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(thisValue));
       
   458     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   459 
       
   460     imp->deleteTFoot();
       
   461     return JSValue::encode(jsUndefined());
       
   462 }
       
   463 
       
   464 EncodedJSValue JSC_HOST_CALL jsHTMLTableElementPrototypeFunctionCreateCaption(ExecState* exec)
       
   465 {
       
   466     JSValue thisValue = exec->hostThisValue();
       
   467     if (!thisValue.inherits(&JSHTMLTableElement::s_info))
       
   468         return throwVMTypeError(exec);
       
   469     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(thisValue));
       
   470     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   471 
       
   472 
       
   473     JSC::JSValue result = toJS(exec, castedThis->globalObject(), WTF::getPtr(imp->createCaption()));
       
   474     return JSValue::encode(result);
       
   475 }
       
   476 
       
   477 EncodedJSValue JSC_HOST_CALL jsHTMLTableElementPrototypeFunctionDeleteCaption(ExecState* exec)
       
   478 {
       
   479     JSValue thisValue = exec->hostThisValue();
       
   480     if (!thisValue.inherits(&JSHTMLTableElement::s_info))
       
   481         return throwVMTypeError(exec);
       
   482     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(thisValue));
       
   483     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   484 
       
   485     imp->deleteCaption();
       
   486     return JSValue::encode(jsUndefined());
       
   487 }
       
   488 
       
   489 EncodedJSValue JSC_HOST_CALL jsHTMLTableElementPrototypeFunctionInsertRow(ExecState* exec)
       
   490 {
       
   491     JSValue thisValue = exec->hostThisValue();
       
   492     if (!thisValue.inherits(&JSHTMLTableElement::s_info))
       
   493         return throwVMTypeError(exec);
       
   494     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(thisValue));
       
   495     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   496     ExceptionCode ec = 0;
       
   497     int index = exec->argument(0).toInt32(exec);
       
   498 
       
   499 
       
   500     JSC::JSValue result = toJS(exec, castedThis->globalObject(), WTF::getPtr(imp->insertRow(index, ec)));
       
   501     setDOMException(exec, ec);
       
   502     return JSValue::encode(result);
       
   503 }
       
   504 
       
   505 EncodedJSValue JSC_HOST_CALL jsHTMLTableElementPrototypeFunctionDeleteRow(ExecState* exec)
       
   506 {
       
   507     JSValue thisValue = exec->hostThisValue();
       
   508     if (!thisValue.inherits(&JSHTMLTableElement::s_info))
       
   509         return throwVMTypeError(exec);
       
   510     JSHTMLTableElement* castedThis = static_cast<JSHTMLTableElement*>(asObject(thisValue));
       
   511     HTMLTableElement* imp = static_cast<HTMLTableElement*>(castedThis->impl());
       
   512     ExceptionCode ec = 0;
       
   513     int index = exec->argument(0).toInt32(exec);
       
   514 
       
   515     imp->deleteRow(index, ec);
       
   516     setDOMException(exec, ec);
       
   517     return JSValue::encode(jsUndefined());
       
   518 }
       
   519 
       
   520 
       
   521 }