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

Side by Side Diff: third_party/WebKit/Source/bindings/tests/results/core/V8TestInterfaceOriginTrialEnabled.cpp

Issue 2733763003: Reimplement [PutForwards] per spec (Closed)
Patch Set: avoid using v8::Maybe Created 3 years, 7 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/interface.cpp.tmpl 9 // third_party/WebKit/Source/bindings/templates/interface.cpp.tmpl
10 10
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 TestInterfaceOriginTrialEnabled* impl = V8TestInterfaceOriginTrialEnabled::toI mpl(holder); 60 TestInterfaceOriginTrialEnabled* impl = V8TestInterfaceOriginTrialEnabled::toI mpl(holder);
61 61
62 V8SetReturnValue(info, impl->doubleAttribute()); 62 V8SetReturnValue(info, impl->doubleAttribute());
63 } 63 }
64 64
65 static void doubleAttributeAttributeSetter(v8::Local<v8::Value> v8Value, const v 8::FunctionCallbackInfo<v8::Value>& info) { 65 static void doubleAttributeAttributeSetter(v8::Local<v8::Value> v8Value, const v 8::FunctionCallbackInfo<v8::Value>& info) {
66 v8::Isolate* isolate = info.GetIsolate(); 66 v8::Isolate* isolate = info.GetIsolate();
67 ALLOW_UNUSED_LOCAL(isolate); 67 ALLOW_UNUSED_LOCAL(isolate);
68 68
69 v8::Local<v8::Object> holder = info.Holder(); 69 v8::Local<v8::Object> holder = info.Holder();
70 ALLOW_UNUSED_LOCAL(holder);
71
70 TestInterfaceOriginTrialEnabled* impl = V8TestInterfaceOriginTrialEnabled::toI mpl(holder); 72 TestInterfaceOriginTrialEnabled* impl = V8TestInterfaceOriginTrialEnabled::toI mpl(holder);
71 73
72 ExceptionState exceptionState(isolate, ExceptionState::kSetterContext, "TestIn terfaceOriginTrialEnabled", "doubleAttribute"); 74 ExceptionState exceptionState(isolate, ExceptionState::kSetterContext, "TestIn terfaceOriginTrialEnabled", "doubleAttribute");
73 75
74 // Prepare the value to be set. 76 // Prepare the value to be set.
75 double cppValue = NativeValueTraits<IDLDouble>::NativeValue(info.GetIsolate(), v8Value, exceptionState); 77 double cppValue = NativeValueTraits<IDLDouble>::NativeValue(info.GetIsolate(), v8Value, exceptionState);
76 if (exceptionState.HadException()) 78 if (exceptionState.HadException())
77 return; 79 return;
78 80
79 impl->setDoubleAttribute(cppValue); 81 impl->setDoubleAttribute(cppValue);
80 } 82 }
81 83
82 static void conditionalLongAttributeAttributeGetter(const v8::FunctionCallbackIn fo<v8::Value>& info) { 84 static void conditionalLongAttributeAttributeGetter(const v8::FunctionCallbackIn fo<v8::Value>& info) {
83 v8::Local<v8::Object> holder = info.Holder(); 85 v8::Local<v8::Object> holder = info.Holder();
84 86
85 TestInterfaceOriginTrialEnabled* impl = V8TestInterfaceOriginTrialEnabled::toI mpl(holder); 87 TestInterfaceOriginTrialEnabled* impl = V8TestInterfaceOriginTrialEnabled::toI mpl(holder);
86 88
87 V8SetReturnValueInt(info, impl->conditionalLongAttribute()); 89 V8SetReturnValueInt(info, impl->conditionalLongAttribute());
88 } 90 }
89 91
90 static void conditionalLongAttributeAttributeSetter(v8::Local<v8::Value> v8Value , const v8::FunctionCallbackInfo<v8::Value>& info) { 92 static void conditionalLongAttributeAttributeSetter(v8::Local<v8::Value> v8Value , const v8::FunctionCallbackInfo<v8::Value>& info) {
91 v8::Isolate* isolate = info.GetIsolate(); 93 v8::Isolate* isolate = info.GetIsolate();
92 ALLOW_UNUSED_LOCAL(isolate); 94 ALLOW_UNUSED_LOCAL(isolate);
93 95
94 v8::Local<v8::Object> holder = info.Holder(); 96 v8::Local<v8::Object> holder = info.Holder();
97 ALLOW_UNUSED_LOCAL(holder);
98
95 TestInterfaceOriginTrialEnabled* impl = V8TestInterfaceOriginTrialEnabled::toI mpl(holder); 99 TestInterfaceOriginTrialEnabled* impl = V8TestInterfaceOriginTrialEnabled::toI mpl(holder);
96 100
97 ExceptionState exceptionState(isolate, ExceptionState::kSetterContext, "TestIn terfaceOriginTrialEnabled", "conditionalLongAttribute"); 101 ExceptionState exceptionState(isolate, ExceptionState::kSetterContext, "TestIn terfaceOriginTrialEnabled", "conditionalLongAttribute");
98 102
99 // Prepare the value to be set. 103 // Prepare the value to be set.
100 int32_t cppValue = NativeValueTraits<IDLLong>::NativeValue(info.GetIsolate(), v8Value, exceptionState, kNormalConversion); 104 int32_t cppValue = NativeValueTraits<IDLLong>::NativeValue(info.GetIsolate(), v8Value, exceptionState, kNormalConversion);
101 if (exceptionState.HadException()) 105 if (exceptionState.HadException())
102 return; 106 return;
103 107
104 impl->setConditionalLongAttribute(cppValue); 108 impl->setConditionalLongAttribute(cppValue);
105 } 109 }
106 110
107 static void conditionalReadOnlyLongAttributeAttributeGetter(const v8::FunctionCa llbackInfo<v8::Value>& info) { 111 static void conditionalReadOnlyLongAttributeAttributeGetter(const v8::FunctionCa llbackInfo<v8::Value>& info) {
108 v8::Local<v8::Object> holder = info.Holder(); 112 v8::Local<v8::Object> holder = info.Holder();
109 113
110 TestInterfaceOriginTrialEnabled* impl = V8TestInterfaceOriginTrialEnabled::toI mpl(holder); 114 TestInterfaceOriginTrialEnabled* impl = V8TestInterfaceOriginTrialEnabled::toI mpl(holder);
111 115
112 V8SetReturnValueInt(info, impl->conditionalReadOnlyLongAttribute()); 116 V8SetReturnValueInt(info, impl->conditionalReadOnlyLongAttribute());
113 } 117 }
114 118
115 static void staticStringAttributeAttributeGetter(const v8::FunctionCallbackInfo< v8::Value>& info) { 119 static void staticStringAttributeAttributeGetter(const v8::FunctionCallbackInfo< v8::Value>& info) {
116 V8SetReturnValueString(info, TestInterfaceOriginTrialEnabled::staticStringAttr ibute(), info.GetIsolate()); 120 V8SetReturnValueString(info, TestInterfaceOriginTrialEnabled::staticStringAttr ibute(), info.GetIsolate());
117 } 121 }
118 122
119 static void staticStringAttributeAttributeSetter(v8::Local<v8::Value> v8Value, c onst v8::FunctionCallbackInfo<v8::Value>& info) { 123 static void staticStringAttributeAttributeSetter(v8::Local<v8::Value> v8Value, c onst v8::FunctionCallbackInfo<v8::Value>& info) {
120 v8::Isolate* isolate = info.GetIsolate(); 124 v8::Isolate* isolate = info.GetIsolate();
121 ALLOW_UNUSED_LOCAL(isolate); 125 ALLOW_UNUSED_LOCAL(isolate);
122 126
127 v8::Local<v8::Object> holder = info.Holder();
128 ALLOW_UNUSED_LOCAL(holder);
129
123 // Prepare the value to be set. 130 // Prepare the value to be set.
124 V8StringResource<> cppValue = v8Value; 131 V8StringResource<> cppValue = v8Value;
125 if (!cppValue.Prepare()) 132 if (!cppValue.Prepare())
126 return; 133 return;
127 134
128 TestInterfaceOriginTrialEnabled::setStaticStringAttribute(cppValue); 135 TestInterfaceOriginTrialEnabled::setStaticStringAttribute(cppValue);
129 } 136 }
130 137
131 static void staticConditionalReadOnlyLongAttributeAttributeGetter(const v8::Func tionCallbackInfo<v8::Value>& info) { 138 static void staticConditionalReadOnlyLongAttributeAttributeGetter(const v8::Func tionCallbackInfo<v8::Value>& info) {
132 V8SetReturnValueInt(info, TestInterfaceOriginTrialEnabled::staticConditionalRe adOnlyLongAttribute()); 139 V8SetReturnValueInt(info, TestInterfaceOriginTrialEnabled::staticConditionalRe adOnlyLongAttribute());
(...skipping 185 matching lines...) Expand 10 before | Expand all | Expand 10 after
318 TestInterfaceOriginTrialEnabled* NativeValueTraits<TestInterfaceOriginTrialEnabl ed>::NativeValue(v8::Isolate* isolate, v8::Local<v8::Value> value, ExceptionStat e& exceptionState) { 325 TestInterfaceOriginTrialEnabled* NativeValueTraits<TestInterfaceOriginTrialEnabl ed>::NativeValue(v8::Isolate* isolate, v8::Local<v8::Value> value, ExceptionStat e& exceptionState) {
319 TestInterfaceOriginTrialEnabled* nativeValue = V8TestInterfaceOriginTrialEnabl ed::toImplWithTypeCheck(isolate, value); 326 TestInterfaceOriginTrialEnabled* nativeValue = V8TestInterfaceOriginTrialEnabl ed::toImplWithTypeCheck(isolate, value);
320 if (!nativeValue) { 327 if (!nativeValue) {
321 exceptionState.ThrowTypeError(ExceptionMessages::FailedToConvertJSValue( 328 exceptionState.ThrowTypeError(ExceptionMessages::FailedToConvertJSValue(
322 "TestInterfaceOriginTrialEnabled")); 329 "TestInterfaceOriginTrialEnabled"));
323 } 330 }
324 return nativeValue; 331 return nativeValue;
325 } 332 }
326 333
327 } // namespace blink 334 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698