Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(120)

Side by Side Diff: Source/bindings/tests/results/core/V8TestInterfaceNamedConstructor.cpp

Issue 819853002: [bindings] Translate all assignments in bindings/templates to use Local<> in place of Handle<>. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 "V8TestInterfaceNamedConstructor.h" 8 #include "V8TestInterfaceNamedConstructor.h"
9 9
10 #include "bindings/core/v8/ExceptionState.h" 10 #include "bindings/core/v8/ExceptionState.h"
(...skipping 14 matching lines...) Expand all
25 25
26 // This static member must be declared by DEFINE_WRAPPERTYPEINFO in TestInterfac eNamedConstructor.h. 26 // This static member must be declared by DEFINE_WRAPPERTYPEINFO in TestInterfac eNamedConstructor.h.
27 // For details, see the comment of DEFINE_WRAPPERTYPEINFO in 27 // For details, see the comment of DEFINE_WRAPPERTYPEINFO in
28 // bindings/core/v8/ScriptWrappable.h. 28 // bindings/core/v8/ScriptWrappable.h.
29 const WrapperTypeInfo& TestInterfaceNamedConstructor::s_wrapperTypeInfo = V8Test InterfaceNamedConstructor::wrapperTypeInfo; 29 const WrapperTypeInfo& TestInterfaceNamedConstructor::s_wrapperTypeInfo = V8Test InterfaceNamedConstructor::wrapperTypeInfo;
30 30
31 namespace TestInterfaceNamedConstructorV8Internal { 31 namespace TestInterfaceNamedConstructorV8Internal {
32 32
33 static void TestInterfaceNamedConstructorConstructorGetter(v8::Local<v8::String> , const v8::PropertyCallbackInfo<v8::Value>& info) 33 static void TestInterfaceNamedConstructorConstructorGetter(v8::Local<v8::String> , const v8::PropertyCallbackInfo<v8::Value>& info)
34 { 34 {
35 v8::Handle<v8::Value> data = info.Data(); 35 v8::Local<v8::Value> data = info.Data();
36 ASSERT(data->IsExternal()); 36 ASSERT(data->IsExternal());
37 V8PerContextData* perContextData = V8PerContextData::from(info.Holder()->Cre ationContext()); 37 V8PerContextData* perContextData = V8PerContextData::from(info.Holder()->Cre ationContext());
38 if (!perContextData) 38 if (!perContextData)
39 return; 39 return;
40 v8SetReturnValue(info, perContextData->constructorForType(WrapperTypeInfo::u nwrap(data))); 40 v8SetReturnValue(info, perContextData->constructorForType(WrapperTypeInfo::u nwrap(data)));
41 } 41 }
42 42
43 static void TestInterfaceNamedConstructorForceSetAttributeOnThis(v8::Local<v8::S tring> name, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info) 43 static void TestInterfaceNamedConstructorForceSetAttributeOnThis(v8::Local<v8::S tring> name, v8::Local<v8::Value> v8Value, const v8::PropertyCallbackInfo<void>& info)
44 { 44 {
45 if (info.This()->IsObject()) 45 if (info.This()->IsObject())
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 } else { 92 } else {
93 defaultNullStringOptionalstringArg = nullptr; 93 defaultNullStringOptionalstringArg = nullptr;
94 } 94 }
95 if (UNLIKELY(info.Length() <= 5)) { 95 if (UNLIKELY(info.Length() <= 5)) {
96 Document& document = *toDocument(currentExecutionContext(info.GetIso late())); 96 Document& document = *toDocument(currentExecutionContext(info.GetIso late()));
97 RefPtr<TestInterfaceNamedConstructor> impl = TestInterfaceNamedConst ructor::createForJSConstructor(document, stringArg, defaultUndefinedOptionalBool eanArg, defaultUndefinedOptionalLongArg, defaultUndefinedOptionalStringArg, defa ultNullStringOptionalstringArg, exceptionState); 97 RefPtr<TestInterfaceNamedConstructor> impl = TestInterfaceNamedConst ructor::createForJSConstructor(document, stringArg, defaultUndefinedOptionalBool eanArg, defaultUndefinedOptionalLongArg, defaultUndefinedOptionalStringArg, defa ultNullStringOptionalstringArg, exceptionState);
98 if (exceptionState.hadException()) { 98 if (exceptionState.hadException()) {
99 exceptionState.throwIfNeeded(); 99 exceptionState.throwIfNeeded();
100 return; 100 return;
101 } 101 }
102 v8::Handle<v8::Object> wrapper = info.Holder(); 102 v8::Local<v8::Object> wrapper = info.Holder();
103 impl->associateWithWrapper(info.GetIsolate(), &V8TestInterfaceNamedC onstructorConstructor::wrapperTypeInfo, wrapper); 103 impl->associateWithWrapper(info.GetIsolate(), &V8TestInterfaceNamedC onstructorConstructor::wrapperTypeInfo, wrapper);
104 v8SetReturnValue(info, wrapper); 104 v8SetReturnValue(info, wrapper);
105 return; 105 return;
106 } 106 }
107 TOSTRING_VOID_INTERNAL(optionalStringArg, info[5]); 107 TOSTRING_VOID_INTERNAL(optionalStringArg, info[5]);
108 } 108 }
109 Document& document = *toDocument(currentExecutionContext(info.GetIsolate())) ; 109 Document& document = *toDocument(currentExecutionContext(info.GetIsolate())) ;
110 RefPtr<TestInterfaceNamedConstructor> impl = TestInterfaceNamedConstructor:: createForJSConstructor(document, stringArg, defaultUndefinedOptionalBooleanArg, defaultUndefinedOptionalLongArg, defaultUndefinedOptionalStringArg, defaultNullS tringOptionalstringArg, optionalStringArg, exceptionState); 110 RefPtr<TestInterfaceNamedConstructor> impl = TestInterfaceNamedConstructor:: createForJSConstructor(document, stringArg, defaultUndefinedOptionalBooleanArg, defaultUndefinedOptionalLongArg, defaultUndefinedOptionalStringArg, defaultNullS tringOptionalstringArg, optionalStringArg, exceptionState);
111 if (exceptionState.hadException()) { 111 if (exceptionState.hadException()) {
112 exceptionState.throwIfNeeded(); 112 exceptionState.throwIfNeeded();
113 return; 113 return;
114 } 114 }
115 v8::Handle<v8::Object> wrapper = info.Holder(); 115 v8::Local<v8::Object> wrapper = info.Holder();
116 impl->associateWithWrapper(info.GetIsolate(), &V8TestInterfaceNamedConstruct orConstructor::wrapperTypeInfo, wrapper); 116 impl->associateWithWrapper(info.GetIsolate(), &V8TestInterfaceNamedConstruct orConstructor::wrapperTypeInfo, wrapper);
117 v8SetReturnValue(info, wrapper); 117 v8SetReturnValue(info, wrapper);
118 } 118 }
119 119
120 v8::Handle<v8::FunctionTemplate> V8TestInterfaceNamedConstructorConstructor::dom Template(v8::Isolate* isolate) 120 v8::Handle<v8::FunctionTemplate> V8TestInterfaceNamedConstructorConstructor::dom Template(v8::Isolate* isolate)
121 { 121 {
122 static int domTemplateKey; // This address is used for a key to look up the dom template. 122 static int domTemplateKey; // This address is used for a key to look up the dom template.
123 V8PerIsolateData* data = V8PerIsolateData::from(isolate); 123 V8PerIsolateData* data = V8PerIsolateData::from(isolate);
124 v8::Local<v8::FunctionTemplate> result = data->existingDOMTemplate(&domTempl ateKey); 124 v8::Local<v8::FunctionTemplate> result = data->existingDOMTemplate(&domTempl ateKey);
125 if (!result.IsEmpty()) 125 if (!result.IsEmpty())
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 { 182 {
183 scriptWrappable->toImpl<TestInterfaceNamedConstructor>()->ref(); 183 scriptWrappable->toImpl<TestInterfaceNamedConstructor>()->ref();
184 } 184 }
185 185
186 void V8TestInterfaceNamedConstructor::derefObject(ScriptWrappable* scriptWrappab le) 186 void V8TestInterfaceNamedConstructor::derefObject(ScriptWrappable* scriptWrappab le)
187 { 187 {
188 scriptWrappable->toImpl<TestInterfaceNamedConstructor>()->deref(); 188 scriptWrappable->toImpl<TestInterfaceNamedConstructor>()->deref();
189 } 189 }
190 190
191 } // namespace blink 191 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698