webengine/osswebengine/DerivedSources/WebCore/JSXPathNSResolver.h
changeset 0 dd21522fd290
equal deleted inserted replaced
-1:000000000000 0:dd21522fd290
       
     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 #ifndef JSXPathNSResolver_H
       
    22 #define JSXPathNSResolver_H
       
    23 
       
    24 
       
    25 #if ENABLE(XPATH)
       
    26 
       
    27 #include "kjs_binding.h"
       
    28 
       
    29 namespace WebCore {
       
    30 
       
    31 class XPathNSResolver;
       
    32 
       
    33 class JSXPathNSResolver : public KJS::DOMObject {
       
    34 public:
       
    35     JSXPathNSResolver(KJS::ExecState*, XPathNSResolver*);
       
    36     virtual ~JSXPathNSResolver();
       
    37     virtual const KJS::ClassInfo* classInfo() const { return &info; }
       
    38     static const KJS::ClassInfo info;
       
    39 
       
    40     enum {
       
    41         // Functions
       
    42         LookupNamespaceURIFuncNum
       
    43     };
       
    44     XPathNSResolver* impl() const { return m_impl.get(); }
       
    45 private:
       
    46     RefPtr<XPathNSResolver> m_impl;
       
    47 };
       
    48 
       
    49 KJS::JSValue* toJS(KJS::ExecState*, XPathNSResolver*);
       
    50 XPathNSResolver* toXPathNSResolver(KJS::JSValue*);
       
    51 
       
    52 class JSXPathNSResolverPrototype : public KJS::JSObject {
       
    53 public:
       
    54     static KJS::JSObject* self(KJS::ExecState* exec);
       
    55     virtual const KJS::ClassInfo* classInfo() const { return &info; }
       
    56     static const KJS::ClassInfo info;
       
    57     bool getOwnPropertySlot(KJS::ExecState*, const KJS::Identifier&, KJS::PropertySlot&);
       
    58     JSXPathNSResolverPrototype(KJS::ExecState* exec)
       
    59         : KJS::JSObject(exec->lexicalInterpreter()->builtinObjectPrototype()) { }
       
    60 };
       
    61 
       
    62 class JSXPathNSResolverPrototypeFunction : public KJS::InternalFunctionImp {
       
    63 public:
       
    64     JSXPathNSResolverPrototypeFunction(KJS::ExecState* exec, int i, int len, const KJS::Identifier& name)
       
    65         : KJS::InternalFunctionImp(static_cast<KJS::FunctionPrototype*>(exec->lexicalInterpreter()->builtinFunctionPrototype()), name)
       
    66         , id(i)
       
    67     {
       
    68         put(exec, exec->propertyNames().length, KJS::jsNumber(len), KJS::DontDelete|KJS::ReadOnly|KJS::DontEnum);
       
    69     }
       
    70     virtual KJS::JSValue* callAsFunction(KJS::ExecState*, KJS::JSObject*, const KJS::List&);
       
    71 
       
    72 private:
       
    73     int id;
       
    74 };
       
    75 
       
    76 } // namespace WebCore
       
    77 
       
    78 #endif // ENABLE(XPATH)
       
    79 
       
    80 #endif