| 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 "LongOrTestDictionary.h" | 7 #include "LongOrTestDictionary.h" |
| 8 | 8 |
| 9 #include "bindings/core/v8/DoubleOrString.h" | 9 #include "bindings/core/v8/DoubleOrString.h" |
| 10 #include "bindings/core/v8/TestInterface2OrUint8Array.h" | 10 #include "bindings/core/v8/TestInterface2OrUint8Array.h" |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 } | 67 } |
| 68 | 68 |
| 69 void V8LongOrTestDictionary::toImpl(v8::Isolate* isolate, v8::Local<v8::Value> v
8Value, LongOrTestDictionary& impl, UnionTypeConversionMode conversionMode, Exce
ptionState& exceptionState) | 69 void V8LongOrTestDictionary::toImpl(v8::Isolate* isolate, v8::Local<v8::Value> v
8Value, LongOrTestDictionary& impl, UnionTypeConversionMode conversionMode, Exce
ptionState& exceptionState) |
| 70 { | 70 { |
| 71 if (v8Value.IsEmpty()) | 71 if (v8Value.IsEmpty()) |
| 72 return; | 72 return; |
| 73 | 73 |
| 74 if (conversionMode == UnionTypeConversionMode::Nullable && isUndefinedOrNull
(v8Value)) | 74 if (conversionMode == UnionTypeConversionMode::Nullable && isUndefinedOrNull
(v8Value)) |
| 75 return; | 75 return; |
| 76 | 76 |
| 77 if (isUndefinedOrNull(v8Value) || v8Value->IsObject()) { | 77 if (isUndefinedOrNull(v8Value) || (v8Value->IsObject() && !v8Value->IsArray(
))) { |
| 78 TestDictionary cppValue; | 78 TestDictionary cppValue; |
| 79 V8TestDictionary::toImpl(isolate, v8Value, cppValue, exceptionState); | 79 V8TestDictionary::toImpl(isolate, v8Value, cppValue, exceptionState); |
| 80 if (exceptionState.hadException()) | 80 if (exceptionState.hadException()) |
| 81 return; | 81 return; |
| 82 impl.setTestDictionary(cppValue); | 82 impl.setTestDictionary(cppValue); |
| 83 return; | 83 return; |
| 84 } | 84 } |
| 85 | 85 |
| 86 if (v8Value->IsNumber()) { | 86 if (v8Value->IsNumber()) { |
| 87 int cppValue = toInt32(isolate, v8Value, NormalConversion, exceptionStat
e); | 87 int cppValue = toInt32(isolate, v8Value, NormalConversion, exceptionStat
e); |
| (...skipping 29 matching lines...) Expand all Loading... |
| 117 } | 117 } |
| 118 | 118 |
| 119 LongOrTestDictionary NativeValueTraits<LongOrTestDictionary>::nativeValue(v8::Is
olate* isolate, v8::Local<v8::Value> value, ExceptionState& exceptionState) | 119 LongOrTestDictionary NativeValueTraits<LongOrTestDictionary>::nativeValue(v8::Is
olate* isolate, v8::Local<v8::Value> value, ExceptionState& exceptionState) |
| 120 { | 120 { |
| 121 LongOrTestDictionary impl; | 121 LongOrTestDictionary impl; |
| 122 V8LongOrTestDictionary::toImpl(isolate, value, impl, UnionTypeConversionMode
::NotNullable, exceptionState); | 122 V8LongOrTestDictionary::toImpl(isolate, value, impl, UnionTypeConversionMode
::NotNullable, exceptionState); |
| 123 return impl; | 123 return impl; |
| 124 } | 124 } |
| 125 | 125 |
| 126 } // namespace blink | 126 } // namespace blink |
| OLD | NEW |