IGrowableSharedDataBlock Interface
A growable shared data block of the script engine whose bytes never move (the bytes of a shared WebAssembly.Memory, which the native code of a WebAssembly runtime reads and writes), created by IJsAdapter<TValue>.CreateGrowableSharedDataBlock. Its members can be called from any thread.
public interface IGrowableSharedDataBlockProperties
| Name | Description |
|---|---|
| Address | The address of the first byte, which never changes while the block is alive. |
| ByteLength | The current length of the block in bytes. |
| DataBlock | The data block of the SharedArrayBuffer objects of the block (see IJsAdapter<TValue>.GetSharedDataBlock). |
Address
ByteLength
DataBlock
The data block of the SharedArrayBuffer objects of the block (see IJsAdapter<TValue>.GetSharedDataBlock).
object DataBlock { get; }Property value
Methods
| Name | Description |
|---|---|
| SetWaiters(ISharedDataBlockWaiters) | Makes Atomics.wait, Atomics.waitAsync and Atomics.notify use waiters for the SharedArrayBuffer objects of the block (the waiters of the WebAssembly runtime). It is called before the scripts get a buffer of the block. |
| TryGrow(int) | Grows the block to newByteLength bytes (the new bytes are zeroed), and returns false when it is less than the current length or greater than the maximum length of the block. |