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

Side by Side Diff: third_party/WebKit/Source/bindings/tests/results/modules/BooleanOrString.cpp

Issue 2595543003: Rename toV8(...) function in Blink to ToV8(...). (Closed)
Patch Set: Rebasing... Created 3 years, 11 months 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. 5 // This file has been auto-generated by code_generator_v8.py.
6 // DO NOT MODIFY! 6 // DO NOT MODIFY!
7 7
8 // This file has been generated from the Jinja2 template in 8 // This file has been generated from the Jinja2 template in
9 // third_party/WebKit/Source/bindings/templates/union_container.cpp.tmpl 9 // third_party/WebKit/Source/bindings/templates/union_container.cpp.tmpl
10 10
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 72
73 { 73 {
74 V8StringResource<> cppValue = v8Value; 74 V8StringResource<> cppValue = v8Value;
75 if (!cppValue.prepare(exceptionState)) 75 if (!cppValue.prepare(exceptionState))
76 return; 76 return;
77 impl.setString(cppValue); 77 impl.setString(cppValue);
78 return; 78 return;
79 } 79 }
80 } 80 }
81 81
82 v8::Local<v8::Value> toV8(const BooleanOrString& impl, v8::Local<v8::Object> cre ationContext, v8::Isolate* isolate) { 82 v8::Local<v8::Value> ToV8(const BooleanOrString& impl, v8::Local<v8::Object> cre ationContext, v8::Isolate* isolate) {
83 switch (impl.m_type) { 83 switch (impl.m_type) {
84 case BooleanOrString::SpecificTypeNone: 84 case BooleanOrString::SpecificTypeNone:
85 return v8::Null(isolate); 85 return v8::Null(isolate);
86 case BooleanOrString::SpecificTypeBoolean: 86 case BooleanOrString::SpecificTypeBoolean:
87 return v8Boolean(impl.getAsBoolean(), isolate); 87 return v8Boolean(impl.getAsBoolean(), isolate);
88 case BooleanOrString::SpecificTypeString: 88 case BooleanOrString::SpecificTypeString:
89 return v8String(isolate, impl.getAsString()); 89 return v8String(isolate, impl.getAsString());
90 default: 90 default:
91 NOTREACHED(); 91 NOTREACHED();
92 } 92 }
93 return v8::Local<v8::Value>(); 93 return v8::Local<v8::Value>();
94 } 94 }
95 95
96 BooleanOrString NativeValueTraits<BooleanOrString>::nativeValue(v8::Isolate* iso late, v8::Local<v8::Value> value, ExceptionState& exceptionState) { 96 BooleanOrString NativeValueTraits<BooleanOrString>::nativeValue(v8::Isolate* iso late, v8::Local<v8::Value> value, ExceptionState& exceptionState) {
97 BooleanOrString impl; 97 BooleanOrString impl;
98 V8BooleanOrString::toImpl(isolate, value, impl, UnionTypeConversionMode::NotNu llable, exceptionState); 98 V8BooleanOrString::toImpl(isolate, value, impl, UnionTypeConversionMode::NotNu llable, exceptionState);
99 return impl; 99 return impl;
100 } 100 }
101 101
102 } // namespace blink 102 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698