WebCore/generated/JSSVGPathSeg.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 
       
    23 #if ENABLE(SVG)
       
    24 
       
    25 #include "JSSVGPathSeg.h"
       
    26 
       
    27 #include "KURL.h"
       
    28 #include "SVGPathSeg.h"
       
    29 #include <runtime/JSNumberCell.h>
       
    30 #include <runtime/JSString.h>
       
    31 #include <wtf/GetPtr.h>
       
    32 
       
    33 using namespace JSC;
       
    34 
       
    35 namespace WebCore {
       
    36 
       
    37 ASSERT_CLASS_FITS_IN_CELL(JSSVGPathSeg);
       
    38 
       
    39 /* Hash table */
       
    40 #if ENABLE(JIT)
       
    41 #define THUNK_GENERATOR(generator) , generator
       
    42 #else
       
    43 #define THUNK_GENERATOR(generator)
       
    44 #endif
       
    45 
       
    46 static const HashTableValue JSSVGPathSegTableValues[4] =
       
    47 {
       
    48     { "pathSegType", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPathSegType), (intptr_t)0 THUNK_GENERATOR(0) },
       
    49     { "pathSegTypeAsLetter", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPathSegTypeAsLetter), (intptr_t)0 THUNK_GENERATOR(0) },
       
    50     { "constructor", DontEnum | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegConstructor), (intptr_t)0 THUNK_GENERATOR(0) },
       
    51     { 0, 0, 0, 0 THUNK_GENERATOR(0) }
       
    52 };
       
    53 
       
    54 #undef THUNK_GENERATOR
       
    55 static JSC_CONST_HASHTABLE HashTable JSSVGPathSegTable = { 8, 7, JSSVGPathSegTableValues, 0 };
       
    56 /* Hash table for constructor */
       
    57 #if ENABLE(JIT)
       
    58 #define THUNK_GENERATOR(generator) , generator
       
    59 #else
       
    60 #define THUNK_GENERATOR(generator)
       
    61 #endif
       
    62 
       
    63 static const HashTableValue JSSVGPathSegConstructorTableValues[21] =
       
    64 {
       
    65     { "PATHSEG_UNKNOWN", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_UNKNOWN), (intptr_t)0 THUNK_GENERATOR(0) },
       
    66     { "PATHSEG_CLOSEPATH", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CLOSEPATH), (intptr_t)0 THUNK_GENERATOR(0) },
       
    67     { "PATHSEG_MOVETO_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_MOVETO_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
    68     { "PATHSEG_MOVETO_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_MOVETO_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
    69     { "PATHSEG_LINETO_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_LINETO_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
    70     { "PATHSEG_LINETO_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_LINETO_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
    71     { "PATHSEG_CURVETO_CUBIC_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_CUBIC_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
    72     { "PATHSEG_CURVETO_CUBIC_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_CUBIC_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
    73     { "PATHSEG_CURVETO_QUADRATIC_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_QUADRATIC_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
    74     { "PATHSEG_CURVETO_QUADRATIC_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_QUADRATIC_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
    75     { "PATHSEG_ARC_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_ARC_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
    76     { "PATHSEG_ARC_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_ARC_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
    77     { "PATHSEG_LINETO_HORIZONTAL_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_LINETO_HORIZONTAL_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
    78     { "PATHSEG_LINETO_HORIZONTAL_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_LINETO_HORIZONTAL_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
    79     { "PATHSEG_LINETO_VERTICAL_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_LINETO_VERTICAL_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
    80     { "PATHSEG_LINETO_VERTICAL_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_LINETO_VERTICAL_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
    81     { "PATHSEG_CURVETO_CUBIC_SMOOTH_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_CUBIC_SMOOTH_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
    82     { "PATHSEG_CURVETO_CUBIC_SMOOTH_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_CUBIC_SMOOTH_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
    83     { "PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
    84     { "PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_QUADRATIC_SMOOTH_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
    85     { 0, 0, 0, 0 THUNK_GENERATOR(0) }
       
    86 };
       
    87 
       
    88 #undef THUNK_GENERATOR
       
    89 static JSC_CONST_HASHTABLE HashTable JSSVGPathSegConstructorTable = { 70, 63, JSSVGPathSegConstructorTableValues, 0 };
       
    90 
       
    91 COMPILE_ASSERT(0 == SVGPathSeg::PATHSEG_UNKNOWN, SVGPathSegEnumPATHSEG_UNKNOWNIsWrongUseDontCheckEnums);
       
    92 COMPILE_ASSERT(1 == SVGPathSeg::PATHSEG_CLOSEPATH, SVGPathSegEnumPATHSEG_CLOSEPATHIsWrongUseDontCheckEnums);
       
    93 COMPILE_ASSERT(2 == SVGPathSeg::PATHSEG_MOVETO_ABS, SVGPathSegEnumPATHSEG_MOVETO_ABSIsWrongUseDontCheckEnums);
       
    94 COMPILE_ASSERT(3 == SVGPathSeg::PATHSEG_MOVETO_REL, SVGPathSegEnumPATHSEG_MOVETO_RELIsWrongUseDontCheckEnums);
       
    95 COMPILE_ASSERT(4 == SVGPathSeg::PATHSEG_LINETO_ABS, SVGPathSegEnumPATHSEG_LINETO_ABSIsWrongUseDontCheckEnums);
       
    96 COMPILE_ASSERT(5 == SVGPathSeg::PATHSEG_LINETO_REL, SVGPathSegEnumPATHSEG_LINETO_RELIsWrongUseDontCheckEnums);
       
    97 COMPILE_ASSERT(6 == SVGPathSeg::PATHSEG_CURVETO_CUBIC_ABS, SVGPathSegEnumPATHSEG_CURVETO_CUBIC_ABSIsWrongUseDontCheckEnums);
       
    98 COMPILE_ASSERT(7 == SVGPathSeg::PATHSEG_CURVETO_CUBIC_REL, SVGPathSegEnumPATHSEG_CURVETO_CUBIC_RELIsWrongUseDontCheckEnums);
       
    99 COMPILE_ASSERT(8 == SVGPathSeg::PATHSEG_CURVETO_QUADRATIC_ABS, SVGPathSegEnumPATHSEG_CURVETO_QUADRATIC_ABSIsWrongUseDontCheckEnums);
       
   100 COMPILE_ASSERT(9 == SVGPathSeg::PATHSEG_CURVETO_QUADRATIC_REL, SVGPathSegEnumPATHSEG_CURVETO_QUADRATIC_RELIsWrongUseDontCheckEnums);
       
   101 COMPILE_ASSERT(10 == SVGPathSeg::PATHSEG_ARC_ABS, SVGPathSegEnumPATHSEG_ARC_ABSIsWrongUseDontCheckEnums);
       
   102 COMPILE_ASSERT(11 == SVGPathSeg::PATHSEG_ARC_REL, SVGPathSegEnumPATHSEG_ARC_RELIsWrongUseDontCheckEnums);
       
   103 COMPILE_ASSERT(12 == SVGPathSeg::PATHSEG_LINETO_HORIZONTAL_ABS, SVGPathSegEnumPATHSEG_LINETO_HORIZONTAL_ABSIsWrongUseDontCheckEnums);
       
   104 COMPILE_ASSERT(13 == SVGPathSeg::PATHSEG_LINETO_HORIZONTAL_REL, SVGPathSegEnumPATHSEG_LINETO_HORIZONTAL_RELIsWrongUseDontCheckEnums);
       
   105 COMPILE_ASSERT(14 == SVGPathSeg::PATHSEG_LINETO_VERTICAL_ABS, SVGPathSegEnumPATHSEG_LINETO_VERTICAL_ABSIsWrongUseDontCheckEnums);
       
   106 COMPILE_ASSERT(15 == SVGPathSeg::PATHSEG_LINETO_VERTICAL_REL, SVGPathSegEnumPATHSEG_LINETO_VERTICAL_RELIsWrongUseDontCheckEnums);
       
   107 COMPILE_ASSERT(16 == SVGPathSeg::PATHSEG_CURVETO_CUBIC_SMOOTH_ABS, SVGPathSegEnumPATHSEG_CURVETO_CUBIC_SMOOTH_ABSIsWrongUseDontCheckEnums);
       
   108 COMPILE_ASSERT(17 == SVGPathSeg::PATHSEG_CURVETO_CUBIC_SMOOTH_REL, SVGPathSegEnumPATHSEG_CURVETO_CUBIC_SMOOTH_RELIsWrongUseDontCheckEnums);
       
   109 COMPILE_ASSERT(18 == SVGPathSeg::PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS, SVGPathSegEnumPATHSEG_CURVETO_QUADRATIC_SMOOTH_ABSIsWrongUseDontCheckEnums);
       
   110 COMPILE_ASSERT(19 == SVGPathSeg::PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL, SVGPathSegEnumPATHSEG_CURVETO_QUADRATIC_SMOOTH_RELIsWrongUseDontCheckEnums);
       
   111 
       
   112 class JSSVGPathSegConstructor : public DOMConstructorObject {
       
   113 public:
       
   114     JSSVGPathSegConstructor(JSC::ExecState*, JSDOMGlobalObject*);
       
   115 
       
   116     virtual bool getOwnPropertySlot(JSC::ExecState*, const JSC::Identifier&, JSC::PropertySlot&);
       
   117     virtual bool getOwnPropertyDescriptor(JSC::ExecState*, const JSC::Identifier&, JSC::PropertyDescriptor&);
       
   118     virtual const JSC::ClassInfo* classInfo() const { return &s_info; }
       
   119     static const JSC::ClassInfo s_info;
       
   120     static PassRefPtr<JSC::Structure> createStructure(JSC::JSValue prototype)
       
   121     {
       
   122         return JSC::Structure::create(prototype, JSC::TypeInfo(JSC::ObjectType, StructureFlags), AnonymousSlotCount);
       
   123     }
       
   124 protected:
       
   125     static const unsigned StructureFlags = JSC::OverridesGetOwnPropertySlot | JSC::ImplementsHasInstance | DOMConstructorObject::StructureFlags;
       
   126 };
       
   127 
       
   128 const ClassInfo JSSVGPathSegConstructor::s_info = { "SVGPathSegConstructor", 0, &JSSVGPathSegConstructorTable, 0 };
       
   129 
       
   130 JSSVGPathSegConstructor::JSSVGPathSegConstructor(ExecState* exec, JSDOMGlobalObject* globalObject)
       
   131     : DOMConstructorObject(JSSVGPathSegConstructor::createStructure(globalObject->objectPrototype()), globalObject)
       
   132 {
       
   133     putDirect(exec->propertyNames().prototype, JSSVGPathSegPrototype::self(exec, globalObject), DontDelete | ReadOnly);
       
   134 }
       
   135 
       
   136 bool JSSVGPathSegConstructor::getOwnPropertySlot(ExecState* exec, const Identifier& propertyName, PropertySlot& slot)
       
   137 {
       
   138     return getStaticValueSlot<JSSVGPathSegConstructor, DOMObject>(exec, &JSSVGPathSegConstructorTable, this, propertyName, slot);
       
   139 }
       
   140 
       
   141 bool JSSVGPathSegConstructor::getOwnPropertyDescriptor(ExecState* exec, const Identifier& propertyName, PropertyDescriptor& descriptor)
       
   142 {
       
   143     return getStaticValueDescriptor<JSSVGPathSegConstructor, DOMObject>(exec, &JSSVGPathSegConstructorTable, this, propertyName, descriptor);
       
   144 }
       
   145 
       
   146 /* Hash table for prototype */
       
   147 #if ENABLE(JIT)
       
   148 #define THUNK_GENERATOR(generator) , generator
       
   149 #else
       
   150 #define THUNK_GENERATOR(generator)
       
   151 #endif
       
   152 
       
   153 static const HashTableValue JSSVGPathSegPrototypeTableValues[21] =
       
   154 {
       
   155     { "PATHSEG_UNKNOWN", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_UNKNOWN), (intptr_t)0 THUNK_GENERATOR(0) },
       
   156     { "PATHSEG_CLOSEPATH", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CLOSEPATH), (intptr_t)0 THUNK_GENERATOR(0) },
       
   157     { "PATHSEG_MOVETO_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_MOVETO_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
   158     { "PATHSEG_MOVETO_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_MOVETO_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
   159     { "PATHSEG_LINETO_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_LINETO_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
   160     { "PATHSEG_LINETO_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_LINETO_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
   161     { "PATHSEG_CURVETO_CUBIC_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_CUBIC_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
   162     { "PATHSEG_CURVETO_CUBIC_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_CUBIC_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
   163     { "PATHSEG_CURVETO_QUADRATIC_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_QUADRATIC_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
   164     { "PATHSEG_CURVETO_QUADRATIC_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_QUADRATIC_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
   165     { "PATHSEG_ARC_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_ARC_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
   166     { "PATHSEG_ARC_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_ARC_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
   167     { "PATHSEG_LINETO_HORIZONTAL_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_LINETO_HORIZONTAL_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
   168     { "PATHSEG_LINETO_HORIZONTAL_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_LINETO_HORIZONTAL_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
   169     { "PATHSEG_LINETO_VERTICAL_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_LINETO_VERTICAL_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
   170     { "PATHSEG_LINETO_VERTICAL_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_LINETO_VERTICAL_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
   171     { "PATHSEG_CURVETO_CUBIC_SMOOTH_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_CUBIC_SMOOTH_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
   172     { "PATHSEG_CURVETO_CUBIC_SMOOTH_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_CUBIC_SMOOTH_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
   173     { "PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS), (intptr_t)0 THUNK_GENERATOR(0) },
       
   174     { "PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL", DontDelete | ReadOnly, (intptr_t)static_cast<PropertySlot::GetValueFunc>(jsSVGPathSegPATHSEG_CURVETO_QUADRATIC_SMOOTH_REL), (intptr_t)0 THUNK_GENERATOR(0) },
       
   175     { 0, 0, 0, 0 THUNK_GENERATOR(0) }
       
   176 };
       
   177 
       
   178 #undef THUNK_GENERATOR
       
   179 static JSC_CONST_HASHTABLE HashTable JSSVGPathSegPrototypeTable = { 70, 63, JSSVGPathSegPrototypeTableValues, 0 };
       
   180 const ClassInfo JSSVGPathSegPrototype::s_info = { "SVGPathSegPrototype", 0, &JSSVGPathSegPrototypeTable, 0 };
       
   181 
       
   182 JSObject* JSSVGPathSegPrototype::self(ExecState* exec, JSGlobalObject* globalObject)
       
   183 {
       
   184     return getDOMPrototype<JSSVGPathSeg>(exec, globalObject);
       
   185 }
       
   186 
       
   187 bool JSSVGPathSegPrototype::getOwnPropertySlot(ExecState* exec, const Identifier& propertyName, PropertySlot& slot)
       
   188 {
       
   189     return getStaticValueSlot<JSSVGPathSegPrototype, JSObject>(exec, &JSSVGPathSegPrototypeTable, this, propertyName, slot);
       
   190 }
       
   191 
       
   192 bool JSSVGPathSegPrototype::getOwnPropertyDescriptor(ExecState* exec, const Identifier& propertyName, PropertyDescriptor& descriptor)
       
   193 {
       
   194     return getStaticValueDescriptor<JSSVGPathSegPrototype, JSObject>(exec, &JSSVGPathSegPrototypeTable, this, propertyName, descriptor);
       
   195 }
       
   196 
       
   197 const ClassInfo JSSVGPathSeg::s_info = { "SVGPathSeg", 0, &JSSVGPathSegTable, 0 };
       
   198 
       
   199 JSSVGPathSeg::JSSVGPathSeg(NonNullPassRefPtr<Structure> structure, JSDOMGlobalObject* globalObject, PassRefPtr<SVGPathSeg> impl)
       
   200     : DOMObjectWithGlobalPointer(structure, globalObject)
       
   201     , m_impl(impl)
       
   202 {
       
   203 }
       
   204 
       
   205 JSSVGPathSeg::~JSSVGPathSeg()
       
   206 {
       
   207     forgetDOMObject(this, impl());
       
   208     JSSVGContextCache::forgetWrapper(this);
       
   209 }
       
   210 
       
   211 JSObject* JSSVGPathSeg::createPrototype(ExecState* exec, JSGlobalObject* globalObject)
       
   212 {
       
   213     return new (exec) JSSVGPathSegPrototype(globalObject, JSSVGPathSegPrototype::createStructure(globalObject->objectPrototype()));
       
   214 }
       
   215 
       
   216 bool JSSVGPathSeg::getOwnPropertySlot(ExecState* exec, const Identifier& propertyName, PropertySlot& slot)
       
   217 {
       
   218     return getStaticValueSlot<JSSVGPathSeg, Base>(exec, &JSSVGPathSegTable, this, propertyName, slot);
       
   219 }
       
   220 
       
   221 bool JSSVGPathSeg::getOwnPropertyDescriptor(ExecState* exec, const Identifier& propertyName, PropertyDescriptor& descriptor)
       
   222 {
       
   223     return getStaticValueDescriptor<JSSVGPathSeg, Base>(exec, &JSSVGPathSegTable, this, propertyName, descriptor);
       
   224 }
       
   225 
       
   226 JSValue jsSVGPathSegPathSegType(ExecState* exec, JSValue slotBase, const Identifier&)
       
   227 {
       
   228     JSSVGPathSeg* castedThis = static_cast<JSSVGPathSeg*>(asObject(slotBase));
       
   229     UNUSED_PARAM(exec);
       
   230     SVGPathSeg* imp = static_cast<SVGPathSeg*>(castedThis->impl());
       
   231     JSValue result = jsNumber(exec, imp->pathSegType());
       
   232     return result;
       
   233 }
       
   234 
       
   235 JSValue jsSVGPathSegPathSegTypeAsLetter(ExecState* exec, JSValue slotBase, const Identifier&)
       
   236 {
       
   237     JSSVGPathSeg* castedThis = static_cast<JSSVGPathSeg*>(asObject(slotBase));
       
   238     UNUSED_PARAM(exec);
       
   239     SVGPathSeg* imp = static_cast<SVGPathSeg*>(castedThis->impl());
       
   240     JSValue result = jsString(exec, imp->pathSegTypeAsLetter());
       
   241     return result;
       
   242 }
       
   243 
       
   244 JSValue jsSVGPathSegConstructor(ExecState* exec, JSValue slotBase, const Identifier&)
       
   245 {
       
   246     JSSVGPathSeg* domObject = static_cast<JSSVGPathSeg*>(asObject(slotBase));
       
   247     return JSSVGPathSeg::getConstructor(exec, domObject->globalObject());
       
   248 }
       
   249 JSValue JSSVGPathSeg::getConstructor(ExecState* exec, JSGlobalObject* globalObject)
       
   250 {
       
   251     return getDOMConstructor<JSSVGPathSegConstructor>(exec, static_cast<JSDOMGlobalObject*>(globalObject));
       
   252 }
       
   253 
       
   254 // Constant getters
       
   255 
       
   256 JSValue jsSVGPathSegPATHSEG_UNKNOWN(ExecState* exec, JSValue, const Identifier&)
       
   257 {
       
   258     return jsNumber(exec, static_cast<int>(0));
       
   259 }
       
   260 
       
   261 JSValue jsSVGPathSegPATHSEG_CLOSEPATH(ExecState* exec, JSValue, const Identifier&)
       
   262 {
       
   263     return jsNumber(exec, static_cast<int>(1));
       
   264 }
       
   265 
       
   266 JSValue jsSVGPathSegPATHSEG_MOVETO_ABS(ExecState* exec, JSValue, const Identifier&)
       
   267 {
       
   268     return jsNumber(exec, static_cast<int>(2));
       
   269 }
       
   270 
       
   271 JSValue jsSVGPathSegPATHSEG_MOVETO_REL(ExecState* exec, JSValue, const Identifier&)
       
   272 {
       
   273     return jsNumber(exec, static_cast<int>(3));
       
   274 }
       
   275 
       
   276 JSValue jsSVGPathSegPATHSEG_LINETO_ABS(ExecState* exec, JSValue, const Identifier&)
       
   277 {
       
   278     return jsNumber(exec, static_cast<int>(4));
       
   279 }
       
   280 
       
   281 JSValue jsSVGPathSegPATHSEG_LINETO_REL(ExecState* exec, JSValue, const Identifier&)
       
   282 {
       
   283     return jsNumber(exec, static_cast<int>(5));
       
   284 }
       
   285 
       
   286 JSValue jsSVGPathSegPATHSEG_CURVETO_CUBIC_ABS(ExecState* exec, JSValue, const Identifier&)
       
   287 {
       
   288     return jsNumber(exec, static_cast<int>(6));
       
   289 }
       
   290 
       
   291 JSValue jsSVGPathSegPATHSEG_CURVETO_CUBIC_REL(ExecState* exec, JSValue, const Identifier&)
       
   292 {
       
   293     return jsNumber(exec, static_cast<int>(7));
       
   294 }
       
   295 
       
   296 JSValue jsSVGPathSegPATHSEG_CURVETO_QUADRATIC_ABS(ExecState* exec, JSValue, const Identifier&)
       
   297 {
       
   298     return jsNumber(exec, static_cast<int>(8));
       
   299 }
       
   300 
       
   301 JSValue jsSVGPathSegPATHSEG_CURVETO_QUADRATIC_REL(ExecState* exec, JSValue, const Identifier&)
       
   302 {
       
   303     return jsNumber(exec, static_cast<int>(9));
       
   304 }
       
   305 
       
   306 JSValue jsSVGPathSegPATHSEG_ARC_ABS(ExecState* exec, JSValue, const Identifier&)
       
   307 {
       
   308     return jsNumber(exec, static_cast<int>(10));
       
   309 }
       
   310 
       
   311 JSValue jsSVGPathSegPATHSEG_ARC_REL(ExecState* exec, JSValue, const Identifier&)
       
   312 {
       
   313     return jsNumber(exec, static_cast<int>(11));
       
   314 }
       
   315 
       
   316 JSValue jsSVGPathSegPATHSEG_LINETO_HORIZONTAL_ABS(ExecState* exec, JSValue, const Identifier&)
       
   317 {
       
   318     return jsNumber(exec, static_cast<int>(12));
       
   319 }
       
   320 
       
   321 JSValue jsSVGPathSegPATHSEG_LINETO_HORIZONTAL_REL(ExecState* exec, JSValue, const Identifier&)
       
   322 {
       
   323     return jsNumber(exec, static_cast<int>(13));
       
   324 }
       
   325 
       
   326 JSValue jsSVGPathSegPATHSEG_LINETO_VERTICAL_ABS(ExecState* exec, JSValue, const Identifier&)
       
   327 {
       
   328     return jsNumber(exec, static_cast<int>(14));
       
   329 }
       
   330 
       
   331 JSValue jsSVGPathSegPATHSEG_LINETO_VERTICAL_REL(ExecState* exec, JSValue, const Identifier&)
       
   332 {
       
   333     return jsNumber(exec, static_cast<int>(15));
       
   334 }
       
   335 
       
   336 JSValue jsSVGPathSegPATHSEG_CURVETO_CUBIC_SMOOTH_ABS(ExecState* exec, JSValue, const Identifier&)
       
   337 {
       
   338     return jsNumber(exec, static_cast<int>(16));
       
   339 }
       
   340 
       
   341 JSValue jsSVGPathSegPATHSEG_CURVETO_CUBIC_SMOOTH_REL(ExecState* exec, JSValue, const Identifier&)
       
   342 {
       
   343     return jsNumber(exec, static_cast<int>(17));
       
   344 }
       
   345 
       
   346 JSValue jsSVGPathSegPATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS(ExecState* exec, JSValue, const Identifier&)
       
   347 {
       
   348     return jsNumber(exec, static_cast<int>(18));
       
   349 }
       
   350 
       
   351 JSValue jsSVGPathSegPATHSEG_CURVETO_QUADRATIC_SMOOTH_REL(ExecState* exec, JSValue, const Identifier&)
       
   352 {
       
   353     return jsNumber(exec, static_cast<int>(19));
       
   354 }
       
   355 
       
   356 SVGPathSeg* toSVGPathSeg(JSC::JSValue value)
       
   357 {
       
   358     return value.inherits(&JSSVGPathSeg::s_info) ? static_cast<JSSVGPathSeg*>(asObject(value))->impl() : 0;
       
   359 }
       
   360 
       
   361 }
       
   362 
       
   363 #endif // ENABLE(SVG)