Update To 11.40.268.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / Source / bindings / tests / results / modules / V8TestInterface5.h
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY!
6
7 #ifndef V8TestInterface5_h
8 #define V8TestInterface5_h
9
10 #if ENABLE(CONDITION)
11 #include "bindings/core/v8/ScriptWrappable.h"
12 #include "bindings/core/v8/V8Binding.h"
13 #include "bindings/core/v8/V8DOMWrapper.h"
14 #include "bindings/core/v8/V8TestInterfaceEmpty.h"
15 #include "bindings/core/v8/WrapperTypeInfo.h"
16 #include "bindings/tests/idls/modules/TestInterface5Implementation.h"
17 #include "platform/heap/Handle.h"
18
19 namespace blink {
20
21 class V8TestInterface5 {
22 public:
23     static bool hasInstance(v8::Handle<v8::Value>, v8::Isolate*);
24     static v8::Handle<v8::Object> findInstanceInPrototypeChain(v8::Handle<v8::Value>, v8::Isolate*);
25     static v8::Handle<v8::FunctionTemplate> domTemplate(v8::Isolate*);
26     static TestInterface5Implementation* toImpl(v8::Handle<v8::Object> object)
27     {
28         return blink::toScriptWrappableBase(object)->toImpl<TestInterface5Implementation>();
29     }
30     static TestInterface5Implementation* toImplWithTypeCheck(v8::Isolate*, v8::Handle<v8::Value>);
31     static const WrapperTypeInfo wrapperTypeInfo;
32     static void refObject(ScriptWrappableBase*);
33     static void derefObject(ScriptWrappableBase*);
34     static void trace(Visitor* visitor, ScriptWrappableBase* scriptWrappableBase)
35     {
36     }
37     static void visitDOMWrapper(v8::Isolate*, ScriptWrappableBase*, const v8::Persistent<v8::Object>&);
38     static ActiveDOMObject* toActiveDOMObject(v8::Handle<v8::Object>);
39     static void legacyCallCustom(const v8::FunctionCallbackInfo<v8::Value>&);
40     static const int internalFieldCount = v8DefaultWrapperInternalFieldCount + 0;
41     static inline ScriptWrappableBase* toScriptWrappableBase(TestInterface5Implementation* impl)
42     {
43         return impl->toScriptWrappableBase();
44     }
45     static void installConditionallyEnabledProperties(v8::Handle<v8::Object>, v8::Isolate*);
46     static void installConditionallyEnabledMethods(v8::Handle<v8::Object>, v8::Isolate*);
47 };
48
49 v8::Handle<v8::Value> toV8(TestInterface5Implementation*, v8::Handle<v8::Object> creationContext, v8::Isolate*);
50
51 template<typename CallbackInfo>
52 inline void v8SetReturnValue(const CallbackInfo& callbackInfo, TestInterface5Implementation* impl)
53 {
54     v8SetReturnValue(callbackInfo, toV8(impl, callbackInfo.Holder(), callbackInfo.GetIsolate()));
55 }
56
57 template<typename CallbackInfo>
58 inline void v8SetReturnValueForMainWorld(const CallbackInfo& callbackInfo, TestInterface5Implementation* impl)
59 {
60      v8SetReturnValue(callbackInfo, toV8(impl, callbackInfo.Holder(), callbackInfo.GetIsolate()));
61 }
62
63 template<typename CallbackInfo>
64 inline void v8SetReturnValueFast(const CallbackInfo& callbackInfo, TestInterface5Implementation* impl, const ScriptWrappable*)
65 {
66      v8SetReturnValue(callbackInfo, toV8(impl, callbackInfo.Holder(), callbackInfo.GetIsolate()));
67 }
68
69 } // namespace blink
70 #endif // ENABLE(CONDITION)
71
72 #endif // V8TestInterface5_h