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

Side by Side Diff: third_party/WebKit/Source/bindings/core/v8/SerializedScriptValue.h

Issue 2845623002: Revert of SharedArrayBuffer throws serializing to indexeddb (Closed)
Patch Set: 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 /* 1 /*
2 * Copyright (C) 2009, 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2009, 2010 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 // The following versions cannot be used, in order to be able to 80 // The following versions cannot be used, in order to be able to
81 // deserialize version 0 SSVs. The class implementation has details. 81 // deserialize version 0 SSVs. The class implementation has details.
82 // DO NOT USE: 35, 64, 68, 73, 78, 82, 83, 85, 91, 98, 102, 108, 123. 82 // DO NOT USE: 35, 64, 68, 73, 78, 82, 83, 85, 91, 98, 102, 108, 123.
83 static constexpr uint32_t kWireFormatVersion = 17; 83 static constexpr uint32_t kWireFormatVersion = 17;
84 84
85 struct SerializeOptions { 85 struct SerializeOptions {
86 STACK_ALLOCATED(); 86 STACK_ALLOCATED();
87 Transferables* transferables = nullptr; 87 Transferables* transferables = nullptr;
88 WebBlobInfoArray* blob_info = nullptr; 88 WebBlobInfoArray* blob_info = nullptr;
89 bool write_wasm_to_stream = false; 89 bool write_wasm_to_stream = false;
90 // Set when serializing a value for storage; e.g. when writing to
91 // IndexedDB.
92 bool for_storage = false;
93 }; 90 };
94 static PassRefPtr<SerializedScriptValue> Serialize(v8::Isolate*, 91 static PassRefPtr<SerializedScriptValue> Serialize(v8::Isolate*,
95 v8::Local<v8::Value>, 92 v8::Local<v8::Value>,
96 const SerializeOptions&, 93 const SerializeOptions&,
97 ExceptionState&); 94 ExceptionState&);
98 static PassRefPtr<SerializedScriptValue> SerializeAndSwallowExceptions( 95 static PassRefPtr<SerializedScriptValue> SerializeAndSwallowExceptions(
99 v8::Isolate*, 96 v8::Isolate*,
100 v8::Local<v8::Value>); 97 v8::Local<v8::Value>);
101 98
102 static PassRefPtr<SerializedScriptValue> Create(); 99 static PassRefPtr<SerializedScriptValue> Create();
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
226 ExceptionState& exception_state) { 223 ExceptionState& exception_state) {
227 return SerializedScriptValue::Serialize( 224 return SerializedScriptValue::Serialize(
228 isolate, value, SerializedScriptValue::SerializeOptions(), 225 isolate, value, SerializedScriptValue::SerializeOptions(),
229 exception_state); 226 exception_state);
230 } 227 }
231 }; 228 };
232 229
233 } // namespace blink 230 } // namespace blink
234 231
235 #endif // SerializedScriptValue_h 232 #endif // SerializedScriptValue_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698