RealDocs

46 results for "array" in function

function
TArray::Add Core

Appends an element to the end of the array and returns its index.

function
TArray::AddDefaulted Core

Appends Count new elements at the end of the array, each default-constructed via DefaultConstructItems.

function
TArray::AddUninitialized Core

Grows the array by Count elements without constructing them, returning the index of the first new slot.

function
TArray::AddUnique Core

Adds an element only if it is not already present in the array.

function
TArray::AddZeroed Core

Appends Count new elements at the end of the array, zero-initialising their memory via FMemory::Memzero.

function
TArray::Append Core

Appends all elements from Source to the end of this array in a single allocation.

function
TArray::AppendHash Core

A static method that feeds the element type's layout descriptor into a SHA1 hash.

function
TArray::BulkSerialize Core

Serializes the entire array as a raw memory blob during loading, bypassing per-element serialization for significant performance gains.

function
TArray::CheckAddress Core

Asserts that the given address does not point into the array's current backing buffer.

function
TArray::CheckInvariants Core

Asserts (in Debug/Development builds only) that ArrayNum >= 0 and ArrayMax >= ArrayNum.

function
TArray::Contains Core

Returns true if the array contains at least one element equal to Item.

function
TArray::ContainsByPredicate Core

Returns true if any element satisfies the predicate.

function
TArray::CopyUnfrozen Core

Reconstructs a live TArray from a frozen (WriteMemoryImage) binary representation by placement-constructing a new TArray at Dst and copying element data through the allocator's CopyUnfrozen path.

function
TArray::CountBytes Core

Reports the array's current and peak memory usage to an accounting archive by calling Ar.

function
TArray::Emplace Core

Constructs a new element in-place at the end of the array using the provided constructor arguments.

function
TArray::EmplaceAt Core

Constructs a new element in-place at the given index, shifting all subsequent elements right by one.

function
TArray::Empty Core

Destructs all elements and sets Num to 0.

function
TArray::Find Core

Searches for Item using operator== and returns true if found, setting Index to its position.

function
TArray::FindByPredicate Core

Returns a pointer to the first element for which Pred returns true, or nullptr if none match.

function
TArray::FindItemByClass Core

Searches a TArray of UObject pointers for the first element whose runtime class matches (via IsA) the template parameter SearchType.

function
TArray::FindLast Core

Searches the array from the end toward the front and returns the index of the last element equal to Item, or INDEX_NONE if not found.

function
TArray::HeapPop Core

Removes and returns the top element (the maximum under the current predicate) from the heap, then re-heapifies the remaining elements.

function
TArray::HeapPopDiscard Core

Removes the top element from the heap without returning it, then re-heapifies.

function
TArray::HeapPush Core

Inserts an element into the array while maintaining max-heap order, sifting the new element up to its correct position.

function
TArray::HeapRemoveAt Core

Removes an arbitrary element at the given index from the heap, then restores heap order by sifting the replacement element both up and down as needed.

function
TArray::HeapSort Core

Sorts the array in ascending order using heap sort.

function
TArray::Heapify Core

Rearranges the array in-place into a valid max-heap ordered by operator< (min value at the root).

function
TArray::Init Core

Resets the array to Number elements, every one a copy of Element.

function
TArray::Insert Core

Inserts a single element at the specified index, shifting all subsequent elements right by one.

function
TArray::InsertDefaulted Core

Inserts Count default-constructed elements at Index, shifting existing elements right.

function
TArray::InsertDefaulted_GetRef Core

Inserts a single default-constructed element at Index and returns a reference to it.

function
TArray::InsertUninitialized Core

Opens a gap of Count uninitialized element slots at Index, shifting later elements right.

function
TArray::InsertZeroed Core

Inserts Count zero-initialized elements at Index by shifting existing elements right and then zeroing the new slots with FMemory::Memzero.

function
TArray::InsertZeroed_GetRef Core

Inserts a single zero-initialized element at Index and returns a reference to it, allowing immediate field-by-field initialization without a second array lookup.

function
TArray::IsEmpty Core

Returns true if the array contains no elements.

function
TArray::Num Core

Returns the number of elements currently in the array.

function
TArray::Pop Core

Removes and returns the last element of the array using move semantics.

function
TArray::Push Core

Appends an element to the end of the array, identical in behaviour to Add().

function
TArray::RangeCheck Core

Validates that an index is within the array bounds, triggering a checkf assertion on failure.

function
TArray::Remove Core

Removes all elements equal to Item and returns the number of elements removed.

function
TArray::RemoveAll Core

Removes all elements for which the predicate returns true, preserving order of remaining elements.

function
TArray::RemoveAllSwap Core

Removes all elements satisfying Predicate using RemoveAtSwap internally, which replaces each removed element with the last element rather than shifting.

function
TArray::RemoveAt Core

Removes the element at Index, destructs it, and shifts all subsequent elements left to close the gap.

function
TArray::RemoveAtSwap Core

Removes the element at Index by filling its slot with element(s) from the end of the array.

function
TArray::RemoveSingle Core

Removes the first occurrence of Item from the array while preserving element order.

function
TArray::RemoveSingleSwap Core

Removes the first occurrence of Item using RemoveAtSwap — the removed slot is filled by the last element, making the actual removal O(1) after the O(N) linear search.