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

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

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.h.tmpl 9 // third_party/WebKit/Source/bindings/templates/union_container.h.tmpl
10 10
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 enum SpecificTypes { 45 enum SpecificTypes {
46 SpecificTypeNone, 46 SpecificTypeNone,
47 SpecificTypeBoolean, 47 SpecificTypeBoolean,
48 SpecificTypeString, 48 SpecificTypeString,
49 }; 49 };
50 SpecificTypes m_type; 50 SpecificTypes m_type;
51 51
52 bool m_boolean; 52 bool m_boolean;
53 String m_string; 53 String m_string;
54 54
55 friend MODULES_EXPORT v8::Local<v8::Value> toV8(const BooleanOrString&, v8::Lo cal<v8::Object>, v8::Isolate*); 55 friend MODULES_EXPORT v8::Local<v8::Value> ToV8(const BooleanOrString&, v8::Lo cal<v8::Object>, v8::Isolate*);
56 }; 56 };
57 57
58 class V8BooleanOrString final { 58 class V8BooleanOrString final {
59 public: 59 public:
60 MODULES_EXPORT static void toImpl(v8::Isolate*, v8::Local<v8::Value>, BooleanO rString&, UnionTypeConversionMode, ExceptionState&); 60 MODULES_EXPORT static void toImpl(v8::Isolate*, v8::Local<v8::Value>, BooleanO rString&, UnionTypeConversionMode, ExceptionState&);
61 }; 61 };
62 62
63 MODULES_EXPORT v8::Local<v8::Value> toV8(const BooleanOrString&, v8::Local<v8::O bject>, v8::Isolate*); 63 MODULES_EXPORT v8::Local<v8::Value> ToV8(const BooleanOrString&, v8::Local<v8::O bject>, v8::Isolate*);
64 64
65 template <class CallbackInfo> 65 template <class CallbackInfo>
66 inline void v8SetReturnValue(const CallbackInfo& callbackInfo, BooleanOrString& impl) { 66 inline void v8SetReturnValue(const CallbackInfo& callbackInfo, BooleanOrString& impl) {
67 v8SetReturnValue(callbackInfo, toV8(impl, callbackInfo.Holder(), callbackInfo. GetIsolate())); 67 v8SetReturnValue(callbackInfo, ToV8(impl, callbackInfo.Holder(), callbackInfo. GetIsolate()));
68 } 68 }
69 69
70 template <> 70 template <>
71 struct NativeValueTraits<BooleanOrString> { 71 struct NativeValueTraits<BooleanOrString> {
72 MODULES_EXPORT static BooleanOrString nativeValue(v8::Isolate*, v8::Local<v8:: Value>, ExceptionState&); 72 MODULES_EXPORT static BooleanOrString nativeValue(v8::Isolate*, v8::Local<v8:: Value>, ExceptionState&);
73 }; 73 };
74 74
75 } // namespace blink 75 } // namespace blink
76 76
77 // We need to set canInitializeWithMemset=true because HeapVector supports 77 // We need to set canInitializeWithMemset=true because HeapVector supports
78 // items that can initialize with memset or have a vtable. It is safe to 78 // items that can initialize with memset or have a vtable. It is safe to
79 // set canInitializeWithMemset=true for a union type object in practice. 79 // set canInitializeWithMemset=true for a union type object in practice.
80 // See https://codereview.chromium.org/1118993002/#msg5 for more details. 80 // See https://codereview.chromium.org/1118993002/#msg5 for more details.
81 WTF_ALLOW_MOVE_AND_INIT_WITH_MEM_FUNCTIONS(blink::BooleanOrString); 81 WTF_ALLOW_MOVE_AND_INIT_WITH_MEM_FUNCTIONS(blink::BooleanOrString);
82 82
83 #endif // BooleanOrString_h 83 #endif // BooleanOrString_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698