Options
All
  • Public
  • Public/Protected
  • All
Menu

A contiguous region of memory.

Hierarchy

  • Memory

Index

Constructors

  • Initializes a new empty Memory object.

    Returns Memory

Properties

byteLength: number
internal
byteOffset: number
internal
obj: number | ArrayBufferLike | GlobalBuffer
internal
empty: Memory

Empty memory.

returns

An empty Memory object.

Accessors

  • get isEmpty(): boolean
  • Indicates if the current memory is empty.

    remarks

    An empty Memory instance is empty if its byte length is 0.

    Returns boolean

    true is the current memory is empty; otherwise false.

  • get length(): number
  • Gets the number of bytes in the current memory.

    Returns number

    A number that indicates the number of contiguous bytes represented by the current Memory instance.

Methods

  • fromBuffer(buffer: ArrayBufferLike): Memory
  • Creates local memory from a buffer like object.

    Parameters

    • buffer: ArrayBufferLike

      The buffer from which memory is required.

    Returns Memory

    A Memory instance that encapsulates buffer and which will satisfy isLocalMemory.

Generated using TypeDoc