#include <v8-value-serializer.h>
Deserializes values from data written with ValueSerializer, or a compatible implementation.
◆ ValueDeserializer() [1/3]
| v8::ValueDeserializer::ValueDeserializer |
( |
Isolate * |
isolate, |
|
|
const uint8_t * |
data, |
|
|
size_t |
size |
|
) |
| |
Constructs a ValueDeserializer over a serialized buffer.
- Parameters
-
| isolate | The Isolate in which deserialized values will be created. |
| data | Pointer to the serialized wire bytes. The caller retains ownership of data, which must remain valid and unmodified for the lifetime of this ValueDeserializer. When V8_ENABLE_SANDBOX is enabled, data must reside outside the sandbox address space to preserve sandbox security guarantees against concurrent in-sandbox mutation. |
| size | Size of data in bytes. |
◆ ValueDeserializer() [2/3]
| v8::ValueDeserializer::ValueDeserializer |
( |
Isolate * |
isolate, |
|
|
const uint8_t * |
data, |
|
|
size_t |
size, |
|
|
Delegate * |
delegate |
|
) |
| |
Constructs a ValueDeserializer over a serialized buffer.
- Parameters
-
| isolate | The Isolate in which deserialized values will be created. |
| data | Pointer to the serialized wire bytes. The caller retains ownership of data, which must remain valid and unmodified for the lifetime of this ValueDeserializer. When V8_ENABLE_SANDBOX is enabled, data must reside outside the sandbox address space to preserve sandbox security guarantees against concurrent in-sandbox mutation. |
| size | Size of data in bytes. |
| delegate | Delegate handling host objects, transfers, and shared values. |
◆ ~ValueDeserializer()
| v8::ValueDeserializer::~ValueDeserializer |
( |
| ) |
|
◆ ValueDeserializer() [3/3]
◆ GetWireFormatVersion()
| uint32_t v8::ValueDeserializer::GetWireFormatVersion |
( |
| ) |
const |
Reads the underlying wire format version. Likely mostly to be useful to legacy code reading old wire format versions. Must be called after ReadHeader.
◆ operator=()
◆ ReadDouble()
| bool v8::ValueDeserializer::ReadDouble |
( |
double * |
value | ) |
|
◆ ReadHeader()
Reads and validates a header (including the format version). May, for example, reject an invalid or unsupported wire format.
◆ ReadRawBytes()
| bool v8::ValueDeserializer::ReadRawBytes |
( |
size_t |
length, |
|
|
const void ** |
data |
|
) |
| |
◆ ReadUint32()
| bool v8::ValueDeserializer::ReadUint32 |
( |
uint32_t * |
value | ) |
|
Reads raw data in various common formats to the buffer. Note that integer types are read in base-128 varint format, not with a binary copy. For use during an override of Delegate::ReadHostObject.
◆ ReadUint64()
| bool v8::ValueDeserializer::ReadUint64 |
( |
uint64_t * |
value | ) |
|
◆ ReadValue()
Deserializes a JavaScript value from the buffer.
◆ SetSharedImmutableBackingStores()
| void v8::ValueDeserializer::SetSharedImmutableBackingStores |
( |
std::vector< std::shared_ptr< v8::BackingStore > > |
backing_stores | ) |
|
◆ SetSupportsLegacyWireFormat()
| void v8::ValueDeserializer::SetSupportsLegacyWireFormat |
( |
bool |
supports_legacy_wire_format | ) |
|
Must be called before ReadHeader to enable support for reading the legacy wire format (i.e., which predates this being shipped).
Don't use this unless you need to read data written by previous versions of blink::ScriptValueSerializer.
◆ TransferArrayBuffer()
| void v8::ValueDeserializer::TransferArrayBuffer |
( |
uint32_t |
transfer_id, |
|
|
Local< ArrayBuffer > |
array_buffer |
|
) |
| |
◆ TransferSharedArrayBuffer()
| void v8::ValueDeserializer::TransferSharedArrayBuffer |
( |
uint32_t |
id, |
|
|
Local< SharedArrayBuffer > |
shared_array_buffer |
|
) |
| |
The documentation for this class was generated from the following file: