API

Class SmartArrayNoDuplicate<T>

Defines an GC Friendly array where the backfield array do not shrink to prevent over allocations. The data in this array can only be present once

Type Parameters

  • T

Hierarchy (View Summary)

Index
data: T[]

The full set of data from the array.

length: number = 0

The active length of the array.

  • Concats the active data with a given array. This ensures no duplicate will be present in the result.

    Parameters

    • array: any

      defines the data to concatenate with.

    Returns void

  • Pushes a value at the end of the active data. If the data is already present, it won t be added again

    Parameters

    • value: T

      defines the object to push in the array.

    Returns boolean

    true if added false if it was already present