Home > rc-js-util > RawVoidPointer
Provides a reference counted wrapper to a pointer malloc‘d from JS and is free‘d on reference count hitting 0.
Signature:
export declare class RawVoidPointer implements IRawVoidPointer, IDebugAllocateListener
Implements: IRawVoidPointer, IDebugAllocateListener
| Constructor | Modifiers | Description |
|---|---|---|
| (constructor)(wrapper, pointer, byteSize) | Constructs a new instance of the RawVoidPointer class |
| Property | Modifiers | Type | Description |
|---|---|---|---|
| byteSize | number | ||
| debugOnAllocate? | (() => void) | (Optional) | |
| onMemoryResize | () => void | ||
| pointer | number | ||
| sharedObject | IReferenceCountedPtr |
| Method | Modifiers | Description |
|---|---|---|
| createOne(wrapper, byteSize) | static |
|
| createOne(wrapper, byteSize, allocationFailThrows) | static |
|
| getDataView() |