TScriptArray

Base dynamic array.

Choose your operating system:

Windows

macOS

Linux

Inheritance Hierarchy

ForAnyElementType

TScriptArray

FScriptArray

References

Module

Core

Header

/Engine/Source/Runtime/Core/Public/Containers/ScriptArray.h

Include

#include "Containers/ScriptArray.h"

Syntax

template<typename AllocatorType>
class TScriptArray : protected ForAnyElementType

Remarks

Base dynamic array. An untyped data array; mirrors a TArray's members, but doesn't need an exact C++ type for its elements.

Variables

Name Description

Protected variable

int32

 

ArrayMax

Protected variable

int32

 

ArrayNum

Constructors

Name Description

Public function

TScriptArray()

Public function

TScriptArray

(
    const TScriptArray&
)

These should really be private, because they shouldn't be called, but there's a bunch of code that needs to be fixed first.

Protected function

TScriptArray

(
    int32 InNum,
    int32 NumBytesPerElement
)

FScriptArray::TScriptArray without an alignment parameter is deprecated.

Protected function

TScriptArray

(
    int32 InNum,
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

Functions

Name Description

Public function

void

 

CountBytes

(
    FArchive& Ar,
    int32 NumBytesPerElement
)

Public function

void

 

Empty

(
    int32 Slack,
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

Public function

void *

 

GetData()

Public function Const

const void &...

 

GetData()

Public function Const

int32

 

GetSlack()

Returns the amount of slack in this array in elements.

Public function

void

 

Insert

(
    int32 Index,
    int32 Count,
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

Public function

void

 

InsertZeroed

(
    int32 Index,
    int32 Count,
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

Public function Const

bool

 

IsEmpty()

Public function Const

bool

 

IsValidIndex

(
    int32 i
)

Public function

void

 

MoveAssign

(
    TScriptArray& Other,
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

Public function Const

int32

 

Num()

Public function

void

 

Remove

(
    int32 Index,
    int32 Count,
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

Protected function

void

 

ResizeGrow

(
    int32 OldNum,
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

Protected function

void

 

ResizeInit

(
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

Protected function

void

 

ResizeShrink

(
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

Protected function

void

 

ResizeTo

(
    int32 NewMax,
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

Public function

void

 

Shrink

(
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

Public function

void

 

SwapMemory

(
    int32 A,
    int32 B,
    int32 NumBytesPerElement
)

Operators

Name Description

Public function

void

 

operator=

(
    const TScriptArray&
)

Deprecated Functions

Name Description

Public function

int32

 

Add

(
    int32 Count,
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

TScriptArray::Add without an alignment parameter is deprecated.

Public function

int32

 

Add

(
    int32 Count,
    int32 NumBytesPerElement
)

TScriptArray::Add without an alignment parameter is deprecated.

Public function

int32

 

AddZeroed

(
    int32 Count,
    int32 NumBytesPerElement,
    uint32 AlignmentOfElement
)

TScriptArray::AddZeroed without an alignment parameter is deprecated.

Public function

int32

 

AddZeroed

(
    int32 Count,
    int32 NumBytesPerElement
)

TScriptArray::AddZeroed without an alignment parameter is deprecated.

Public function

void

 

Empty

(
    int32 Slack,
    int32 NumBytesPerElement
)

TScriptArray::Empty without an alignment parameter is deprecated.

Public function

void

 

Insert

(
    int32 Index,
    int32 Count,
    int32 NumBytesPerElement
)

TScriptArray::Insert without an alignment parameter is deprecated.

Public function

void

 

InsertZeroed

(
    int32 Index,
    int32 Count,
    int32 NumBytesPerElement
)

TScriptArray::InsertZeroed without an alignment parameter is deprecated.

Public function

void

 

MoveAssign

(
    TScriptArray& Other,
    int32 NumBytesPerElement
)

TScriptArray::MoveAssign without an alignment parameter is deprecated.

Public function

void

 

Remove

(
    int32 Index,
    int32 Count,
    int32 NumBytesPerElement
)

TScriptArray::Remove without an alignment parameter is deprecated.

Public function

void

 

Shrink

(
    int32 NumBytesPerElement
)

TScriptArray::Shrink without an alignment parameter is deprecated.

Protected function

 

TScriptArray

(
    int32 InNum,
    int32 NumBytesPerElement
)

FScriptArray::TScriptArray without an alignment parameter is deprecated.