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

Unified Diff: Source/bindings/core/v8/NativeValueTraits.h

Issue 1009503003: [bindings] Introduce ScriptValue.to<T> to convert to native values. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Patch for landing Created 5 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/bindings/core/v8/ScriptValue.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/core/v8/NativeValueTraits.h
diff --git a/Source/bindings/core/v8/NativeValueTraits.h b/Source/bindings/core/v8/NativeValueTraits.h
new file mode 100644
index 0000000000000000000000000000000000000000..fc95a817db80b03de527265b792f0c03925de88b
--- /dev/null
+++ b/Source/bindings/core/v8/NativeValueTraits.h
@@ -0,0 +1,21 @@
+// Copyright (c) 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef NativeValueTraits_h
+#define NativeValueTraits_h
+
+#include <v8.h>
+
+namespace blink {
+
+class ExceptionState;
+
+template <typename T>
+struct NativeValueTraits {
+ static T nativeValue(const v8::Local<v8::Value>&, v8::Isolate*, ExceptionState&);
+};
+
+} // namespace blink
+
+#endif // NativeValueTraits_h
« no previous file with comments | « no previous file | Source/bindings/core/v8/ScriptValue.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698