Home > rc-js-util > SharedArray
Typed array shared between wasm and javascript.
Signature:
export declare class SharedArray<TCtor extends TTypedArrayCtor> implements ISharedArray<TCtor>, IOnMemoryResize, IDebugAllocateListener
Implements: ISharedArray<TCtor>, IOnMemoryResize, IDebugAllocateListener
| Constructor | Modifiers | Description |
|---|---|---|
| (constructor)(cMethodPrefix, ctor, wrapper, length, pointer) | Constructs a new instance of the SharedArray class |
| Property | Modifiers | Type | Description |
|---|---|---|---|
| ctor | TCtor | ||
| debugOnAllocate? | (() => void) | (Optional) | |
| elementByteSize | number | ||
| length | number | ||
| onMemoryResize | () => void | ||
| sharedObject | IReferenceCountedPtr |
| Method | Modifiers | Description |
|---|---|---|
| createOneF32(wrapper, length, clearMemory) | static |
|
| createOneF32(wrapper, length, clearMemory, allocationFailThrows) | static |
|
| createOneF64(wrapper, length, clearMemory) | static |
|
| createOneF64(wrapper, length, clearMemory, allocationFailThrows) | static |
|
| getInstance() |