Home | History | Annotate | Download | only in V8
      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., 59 Temple Place - Suite 330,
     18     Boston, MA 02111-1307, USA.
     19 */
     20 
     21 #ifndef V8TestMediaQueryListListener_h
     22 #define V8TestMediaQueryListListener_h
     23 
     24 #include "TestMediaQueryListListener.h"
     25 #include "V8DOMWrapper.h"
     26 #include "WrapperTypeInfo.h"
     27 #include <wtf/text/StringHash.h>
     28 #include <v8.h>
     29 #include <wtf/HashMap.h>
     30 
     31 namespace WebCore {
     32 
     33 class V8TestMediaQueryListListener {
     34 
     35 public:
     36     static bool HasInstance(v8::Handle<v8::Value> value);
     37     static v8::Persistent<v8::FunctionTemplate> GetRawTemplate();
     38     static v8::Persistent<v8::FunctionTemplate> GetTemplate();
     39     static TestMediaQueryListListener* toNative(v8::Handle<v8::Object> object)
     40     {
     41         return reinterpret_cast<TestMediaQueryListListener*>(object->GetPointerFromInternalField(v8DOMWrapperObjectIndex));
     42     }
     43     inline static v8::Handle<v8::Object> wrap(TestMediaQueryListListener*);
     44     static void derefObject(void*);
     45     static WrapperTypeInfo info;
     46     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
     47 private:
     48     static v8::Handle<v8::Object> wrapSlow(TestMediaQueryListListener*);
     49 };
     50 
     51 
     52 v8::Handle<v8::Object> V8TestMediaQueryListListener::wrap(TestMediaQueryListListener* impl)
     53 {
     54         v8::Handle<v8::Object> wrapper = getDOMObjectMap().get(impl);
     55         if (!wrapper.IsEmpty())
     56             return wrapper;
     57     return V8TestMediaQueryListListener::wrapSlow(impl);
     58 }
     59 
     60 inline v8::Handle<v8::Value> toV8(TestMediaQueryListListener* impl)
     61 {
     62     if (!impl)
     63         return v8::Null();
     64     return V8TestMediaQueryListListener::wrap(impl);
     65 }
     66 inline v8::Handle<v8::Value> toV8(PassRefPtr< TestMediaQueryListListener > impl)
     67 {
     68     return toV8(impl.get());
     69 }
     70 }
     71 
     72 #endif // V8TestMediaQueryListListener_h
     73