5#ifndef INCLUDE_V8_VALUE_SERIALIZER_H_
6#define INCLUDE_V8_VALUE_SERIALIZER_H_
23class SharedArrayBuffer;
25class WasmModuleObject;
29struct ScriptStreamingData;
30class SharedObjectConveyorHandles;
31class ValueDeserializer;
58 std::unique_ptr<internal::SharedObjectConveyorHandles> private_;
143 size_t* actual_size);
208 PrivateData* private_;
233 Isolate* isolate, uint32_t transfer_id);
240 Isolate* isolate, uint32_t clone_id);
311 PrivateData* private_;
Definition: v8-isolate.h:212
Definition: v8-local-handle.h:266
Definition: v8-local-handle.h:632
Definition: v8-maybe.h:32
Definition: v8-value-serializer.h:45
SharedValueConveyor(SharedValueConveyor &&) noexcept
Definition: v8-value-serializer.h:217
virtual const SharedValueConveyor * GetSharedValueConveyor(Isolate *isolate)
virtual MaybeLocal< Object > ReadHostObject(Isolate *isolate)
virtual MaybeLocal< SharedArrayBuffer > GetSharedArrayBufferFromId(Isolate *isolate, uint32_t clone_id)
virtual ~Delegate()=default
virtual MaybeLocal< WasmModuleObject > GetWasmModuleFromId(Isolate *isolate, uint32_t transfer_id)
Definition: v8-value-serializer.h:215
bool ReadUint64(uint64_t *value)
void SetSupportsLegacyWireFormat(bool supports_legacy_wire_format)
ValueDeserializer(Isolate *isolate, const uint8_t *data, size_t size, Delegate *delegate)
void TransferSharedArrayBuffer(uint32_t id, Local< SharedArrayBuffer > shared_array_buffer)
bool ReadDouble(double *value)
ValueDeserializer(const ValueDeserializer &)=delete
bool ReadUint32(uint32_t *value)
void operator=(const ValueDeserializer &)=delete
void TransferArrayBuffer(uint32_t transfer_id, Local< ArrayBuffer > array_buffer)
ValueDeserializer(Isolate *isolate, const uint8_t *data, size_t size)
Maybe< bool > ReadHeader(Local< Context > context)
MaybeLocal< Value > ReadValue(Local< Context > context)
uint32_t GetWireFormatVersion() const
bool ReadRawBytes(size_t length, const void **data)
Definition: v8-value-serializer.h:67
virtual void * ReallocateBufferMemory(void *old_buffer, size_t size, size_t *actual_size)
virtual Maybe< uint32_t > GetSharedArrayBufferId(Isolate *isolate, Local< SharedArrayBuffer > shared_array_buffer)
virtual Maybe< uint32_t > GetWasmModuleTransferId(Isolate *isolate, Local< WasmModuleObject > module)
virtual void ThrowDataCloneError(Local< String > message)=0
virtual ~Delegate()=default
virtual bool HasCustomHostObject(Isolate *isolate)
virtual void FreeBufferMemory(void *buffer)
virtual Maybe< bool > IsHostObject(Isolate *isolate, Local< Object > object)
virtual bool AdoptSharedValueConveyor(Isolate *isolate, SharedValueConveyor &&conveyor)
virtual Maybe< bool > WriteHostObject(Isolate *isolate, Local< Object > object)
Definition: v8-value-serializer.h:65
void TransferArrayBuffer(uint32_t transfer_id, Local< ArrayBuffer > array_buffer)
void WriteUint64(uint64_t value)
void WriteDouble(double value)
ValueSerializer(Isolate *isolate)
std::pair< uint8_t *, size_t > Release()
ValueSerializer(Isolate *isolate, Delegate *delegate)
ValueSerializer(const ValueSerializer &)=delete
void operator=(const ValueSerializer &)=delete
void WriteUint32(uint32_t value)
Maybe< bool > WriteValue(Local< Context > context, Local< Value > value)
void WriteRawBytes(const void *source, size_t length)
void SetTreatArrayBufferViewsAsHostObjects(bool mode)
Definition: libplatform.h:15
#define V8_EXPORT
Definition: v8config.h:793
#define V8_WARN_UNUSED_RESULT
Definition: v8config.h:660