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

Side by Side Diff: third_party/WebKit/Source/bindings/modules/v8/ScriptValueSerializerForModules.h

Issue 2087143002: [Binding] [Refactoring] Create Writer and Serializer in one method (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix Debug build Created 4 years, 6 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 #ifndef ScriptValueSerializerForModules_h 5 #ifndef ScriptValueSerializerForModules_h
6 #define ScriptValueSerializerForModules_h 6 #define ScriptValueSerializerForModules_h
7 7
8 #include "bindings/core/v8/ScriptValueSerializer.h" 8 #include "bindings/core/v8/ScriptValueSerializer.h"
9 #include "modules/mediastream/RTCCertificate.h" 9 #include "modules/mediastream/RTCCertificate.h"
10 #include "public/platform/WebCrypto.h" 10 #include "public/platform/WebCrypto.h"
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 bool doReadNamedCurve(WebCryptoNamedCurve&); 66 bool doReadNamedCurve(WebCryptoNamedCurve&);
67 bool doReadKeyUsages(WebCryptoKeyUsageMask& usages, bool& extractable); 67 bool doReadKeyUsages(WebCryptoKeyUsageMask& usages, bool& extractable);
68 }; 68 };
69 69
70 DEFINE_TYPE_CASTS(SerializedScriptValueReaderForModules, SerializedScriptValueRe ader, reader, true, true); 70 DEFINE_TYPE_CASTS(SerializedScriptValueReaderForModules, SerializedScriptValueRe ader, reader, true, true);
71 71
72 class ScriptValueSerializerForModules final : public ScriptValueSerializer { 72 class ScriptValueSerializerForModules final : public ScriptValueSerializer {
73 STACK_ALLOCATED(); 73 STACK_ALLOCATED();
74 WTF_MAKE_NONCOPYABLE(ScriptValueSerializerForModules); 74 WTF_MAKE_NONCOPYABLE(ScriptValueSerializerForModules);
75 public: 75 public:
76 ScriptValueSerializerForModules(SerializedScriptValueWriter&, const Transfer ables*, WebBlobInfoArray*, BlobDataHandleMap&, v8::TryCatch&, ScriptState*); 76 ScriptValueSerializerForModules(SerializedScriptValueWriter&, const Transfer ables*, WebBlobInfoArray*, ScriptState*);
77 77
78 private: 78 private:
79 ScriptValueSerializer::StateBase* doSerializeObject(v8::Local<v8::Object>, S criptValueSerializer::StateBase* next) override; 79 ScriptValueSerializer::StateBase* doSerializeObject(v8::Local<v8::Object>, S criptValueSerializer::StateBase* next) override;
80 80
81 ScriptValueSerializer::StateBase* writeDOMFileSystem(v8::Local<v8::Value>, S criptValueSerializer::StateBase* next); 81 ScriptValueSerializer::StateBase* writeDOMFileSystem(v8::Local<v8::Value>, S criptValueSerializer::StateBase* next);
82 bool writeCryptoKey(v8::Local<v8::Value>); 82 bool writeCryptoKey(v8::Local<v8::Value>);
83 ScriptValueSerializer::StateBase* writeRTCCertificate(v8::Local<v8::Value>, ScriptValueSerializer::StateBase* next); 83 ScriptValueSerializer::StateBase* writeRTCCertificate(v8::Local<v8::Value>, ScriptValueSerializer::StateBase* next);
84 }; 84 };
85 85
86 class ScriptValueDeserializerForModules final : public ScriptValueDeserializer { 86 class ScriptValueDeserializerForModules final : public ScriptValueDeserializer {
87 STACK_ALLOCATED(); 87 STACK_ALLOCATED();
88 WTF_MAKE_NONCOPYABLE(ScriptValueDeserializerForModules); 88 WTF_MAKE_NONCOPYABLE(ScriptValueDeserializerForModules);
89 public: 89 public:
90 ScriptValueDeserializerForModules(SerializedScriptValueReaderForModules&, Me ssagePortArray* messagePorts, ArrayBufferContentsArray*, ImageBitmapContentsArra y*); 90 ScriptValueDeserializerForModules(SerializedScriptValueReaderForModules&, Me ssagePortArray* messagePorts, ArrayBufferContentsArray*, ImageBitmapContentsArra y*);
91 91
92 private: 92 private:
93 bool read(v8::Local<v8::Value>*) override; 93 bool read(v8::Local<v8::Value>*) override;
94 }; 94 };
95 95
96 } // namespace blink 96 } // namespace blink
97 97
98 #endif // ScriptValueSerializerForModules_h 98 #endif // ScriptValueSerializerForModules_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698