OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY! | 5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY! |
6 | 6 |
7 #include "config.h" | 7 #include "config.h" |
8 #include "V8TestInterfaceWillBeGarbageCollected.h" | 8 #include "V8TestInterfaceWillBeGarbageCollected.h" |
9 | 9 |
10 #include "bindings/core/v8/ExceptionState.h" | 10 #include "bindings/core/v8/ExceptionState.h" |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
91 | 91 |
92 static void funcMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) | 92 static void funcMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
93 { | 93 { |
94 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); | 94 TRACE_EVENT_SET_SAMPLING_STATE("blink", "DOMMethod"); |
95 TestInterfaceWillBeGarbageCollectedV8Internal::funcMethod(info); | 95 TestInterfaceWillBeGarbageCollectedV8Internal::funcMethod(info); |
96 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); | 96 TRACE_EVENT_SET_SAMPLING_STATE("v8", "V8Execution"); |
97 } | 97 } |
98 | 98 |
99 static void constructor(const v8::FunctionCallbackInfo<v8::Value>& info) | 99 static void constructor(const v8::FunctionCallbackInfo<v8::Value>& info) |
100 { | 100 { |
101 if (UNLIKELY(info.Length() < 1)) { | 101 if (info.Length() < 1) { |
102 throwMinimumArityTypeErrorForConstructor("TestInterfaceWillBeGarbageColl
ected", 1, info.Length(), info.GetIsolate()); | 102 throwMinimumArityTypeErrorForConstructor("TestInterfaceWillBeGarbageColl
ected", 1, info.Length(), info.GetIsolate()); |
103 return; | 103 return; |
104 } | 104 } |
105 V8StringResource<> str; | 105 V8StringResource<> str; |
106 { | 106 { |
107 TOSTRING_VOID_INTERNAL(str, info[0]); | 107 TOSTRING_VOID_INTERNAL(str, info[0]); |
108 } | 108 } |
109 RefPtrWillBeRawPtr<TestInterfaceWillBeGarbageCollected> impl = TestInterface
WillBeGarbageCollected::create(str); | 109 RefPtrWillBeRawPtr<TestInterfaceWillBeGarbageCollected> impl = TestInterface
WillBeGarbageCollected::create(str); |
110 v8::Handle<v8::Object> wrapper = info.Holder(); | 110 v8::Handle<v8::Object> wrapper = info.Holder(); |
111 V8DOMWrapper::associateObjectWithWrapper<V8TestInterfaceWillBeGarbageCollect
ed>(impl.release(), &V8TestInterfaceWillBeGarbageCollected::wrapperTypeInfo, wra
pper, info.GetIsolate(), WrapperConfiguration::Independent); | 111 V8DOMWrapper::associateObjectWithWrapper<V8TestInterfaceWillBeGarbageCollect
ed>(impl.release(), &V8TestInterfaceWillBeGarbageCollected::wrapperTypeInfo, wra
pper, info.GetIsolate(), WrapperConfiguration::Independent); |
(...skipping 16 matching lines...) Expand all Loading... |
128 { | 128 { |
129 if (!info.IsConstructCall()) { | 129 if (!info.IsConstructCall()) { |
130 throwTypeError(ExceptionMessages::constructorNotCallableAsFunction("Test
Interface"), info.GetIsolate()); | 130 throwTypeError(ExceptionMessages::constructorNotCallableAsFunction("Test
Interface"), info.GetIsolate()); |
131 return; | 131 return; |
132 } | 132 } |
133 | 133 |
134 if (ConstructorMode::current(info.GetIsolate()) == ConstructorMode::WrapExis
tingObject) { | 134 if (ConstructorMode::current(info.GetIsolate()) == ConstructorMode::WrapExis
tingObject) { |
135 v8SetReturnValue(info, info.Holder()); | 135 v8SetReturnValue(info, info.Holder()); |
136 return; | 136 return; |
137 } | 137 } |
138 if (UNLIKELY(info.Length() < 1)) { | 138 if (info.Length() < 1) { |
139 throwMinimumArityTypeErrorForConstructor("TestInterfaceWillBeGarbageColl
ected", 1, info.Length(), info.GetIsolate()); | 139 throwMinimumArityTypeErrorForConstructor("TestInterfaceWillBeGarbageColl
ected", 1, info.Length(), info.GetIsolate()); |
140 return; | 140 return; |
141 } | 141 } |
142 V8StringResource<> str; | 142 V8StringResource<> str; |
143 { | 143 { |
144 TOSTRING_VOID_INTERNAL(str, info[0]); | 144 TOSTRING_VOID_INTERNAL(str, info[0]); |
145 } | 145 } |
146 RefPtrWillBeRawPtr<TestInterfaceWillBeGarbageCollected> impl = TestInterface
WillBeGarbageCollected::createForJSConstructor(str); | 146 RefPtrWillBeRawPtr<TestInterfaceWillBeGarbageCollected> impl = TestInterface
WillBeGarbageCollected::createForJSConstructor(str); |
147 v8::Handle<v8::Object> wrapper = info.Holder(); | 147 v8::Handle<v8::Object> wrapper = info.Holder(); |
148 V8DOMWrapper::associateObjectWithWrapper<V8TestInterfaceWillBeGarbageCollect
ed>(impl.release(), &V8TestInterfaceWillBeGarbageCollectedConstructor::wrapperTy
peInfo, wrapper, info.GetIsolate(), WrapperConfiguration::Independent); | 148 V8DOMWrapper::associateObjectWithWrapper<V8TestInterfaceWillBeGarbageCollect
ed>(impl.release(), &V8TestInterfaceWillBeGarbageCollectedConstructor::wrapperTy
peInfo, wrapper, info.GetIsolate(), WrapperConfiguration::Independent); |
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
261 #endif // !ENABLE(OILPAN) | 261 #endif // !ENABLE(OILPAN) |
262 } | 262 } |
263 | 263 |
264 template<> | 264 template<> |
265 v8::Handle<v8::Value> toV8NoInline(TestInterfaceWillBeGarbageCollected* impl, v8
::Handle<v8::Object> creationContext, v8::Isolate* isolate) | 265 v8::Handle<v8::Value> toV8NoInline(TestInterfaceWillBeGarbageCollected* impl, v8
::Handle<v8::Object> creationContext, v8::Isolate* isolate) |
266 { | 266 { |
267 return toV8(impl, creationContext, isolate); | 267 return toV8(impl, creationContext, isolate); |
268 } | 268 } |
269 | 269 |
270 } // namespace blink | 270 } // namespace blink |
OLD | NEW |