LocalL4UInt16Array (struct)

The LocalL4UInt16Array is an efficient container for storing UInt16 values, where up to 4 values can be added without requiring memory allocations on the heap. This allows to efficiently contain array of values, where arrays are usually smaller than 4.

注釈

Avoiding frequent heap memory allocations can have a significant performance impact. Using this type can avoid the memory allocation overhead in some scenarios (eg: various PolygonMesh methods use local arrays).

LocalL4UInt16Array LocalL4UInt16Array LocalL4UInt16Array

Members

UInt16[4] first4  
UInt16[] others  
UInt32 count  

Methods

  LocalL4UInt16Array ( in LocalL4UInt16Array other )
  LocalL4UInt16Array ()
LocalL4UInt16Array clone ? ()
UInt16 get ? ( in UInt32 index )
String getString ? ()
  push ! ( in UInt16 value )
  resize ! ( in UInt32 size )
  set ! ( in UInt32 index, in UInt16 value )
UInt32 size ? ()

Operators

LocalL4UInt16Array = ( Param other )

Methods in detail

LocalL4UInt16Array ( in LocalL4UInt16Array other )

copy constructor


LocalL4UInt16Array ()

default constructor


LocalL4UInt16Array LocalL4UInt16Array.clone? ()

clone method


UInt16 LocalL4UInt16Array.get? ( in UInt32 index )

returns the value stored at an index.


String LocalL4UInt16Array.getString? ()

returns a description of the array as a String


LocalL4UInt16Array.push! ( in UInt16 value )

appends a new UInt16 value to the end of the array


LocalL4UInt16Array.resize! ( in UInt32 size )

resizes the array.


LocalL4UInt16Array.set! ( in UInt32 index, in UInt16 value )

sets the value stored at an index


UInt32 LocalL4UInt16Array.size? ()

returns the size of the array (number of UInt16 elements stored).

Operators in detail

LocalL4UInt16Array = ( Param other )

copy the content of another LocalL4UInt16Array