Navigation
API > API/Plugins > API/Plugins/StructUtils
References
| Module | StructUtils |
| Header | /Engine/Plugins/Experimental/StructUtils/Source/StructUtils/Public/StructArrayView.h |
| Include | #include "StructArrayView.h" |
Syntax
struct FConstStructArrayView
Remarks
A generic, transient view of a homogeneously-typed array of instances of a specific UScriptStructFConstStructArrayView supplies immutable access to the elements of the Array. For a more indepth overview of the constness of views see FConstStructView
Constructors
| Type | Name | Description | |
|---|---|---|---|
FConstStructArrayView
(
TArray< T >& InArray |
|||
FConstStructArrayView
(
TArrayView< T > InArrayView |
|||
FConstStructArrayView
(
const FStructArrayView Src |
|||
FConstStructArrayView
(
const UScriptStruct& InScriptStruct, |
|||
FConstStructArrayView
(
const UScriptStruct* InScriptStruct, |
Functions
| Type | Name | Description | |
|---|---|---|---|
| FIterator | begin () |
Ranged iteration support. DO NOT USE DIRECTLY. | |
| void | Checks array invariants: if array size is greater than or equal to zero. | ||
| FIterator | end () |
||
| constexpr TEnableIf< TIsConst< T >::Value, T & >::Type | GetAt
(
const int32 Index |
Returns reference to element at given index. | |
| const void * | GetData () |
Helper function for returning a pointer to the first array entry. | |
| const void * | GetDataAt
(
const int32 Index |
Helper function for returning a pointer to an element in the array. | |
| constexpr TEnableIf< TIsConst< T >::Value, T * >::Type | GetPtrAt
(
const int32 Index |
Returns pointer to element at given index. | |
| const UScriptStruct * | Returns struct type. | ||
| uint32 | GetTypeSize () |
Helper function returning the size of the inner type. | |
| bool | IsEmpty () |
Returns true if the array is empty and contains no elements. | |
| bool | IsValidIndex
(
int32 Index |
Tests if index is valid, i.e. greater than or equal to zero, and less than the number of elements in the array. | |
| constexpr TEnableIf< TIsConst< T >::Value, T & >::Type | Last
(
int32 IndexFromTheEnd |
Returns n-th last element from the array. | |
| FConstStructArrayView | Left
(
const int32 Count |
Returns the left-most part of the view by taking the given number of elements from the left. | |
| FConstStructArrayView | LeftChop
(
const int32 Count |
Returns the left-most part of the view by chopping the given number of elements from the right. | |
| void | LeftChopInline
(
const int32 Count |
Modifies the view by chopping the given number of elements from the right. | |
| void | LeftInline
(
const int32 Count |
Modifies the view to be the given number of elements from the left. | |
| FConstStructArrayView | Mid
(
int32 Index, |
Returns the middle part of the view by taking up to the given number of elements from the given position. | |
| void | MidInline
(
const int32 Position, |
Modifies the view to be the middle part by taking up to the given number of elements from the given position. | |
| int32 | Num () |
Returns number of elements in array. | |
| void | RangeCheck
(
int32 Index |
Checks if index is in array range. | |
| FConstStructArrayView | Right
(
const int32 Count |
Returns the right-most part of the view by taking the given number of elements from the right. | |
| FConstStructArrayView | RightChop
(
const int32 Count |
Returns the right-most part of the view by chopping the given number of elements from the left. | |
| void | RightChopInline
(
const int32 Count |
Modifies the view by chopping the given number of elements from the left. | |
| void | RightInline
(
const int32 Count |
Modifies the view to be the given number of elements from the right. | |
| FConstStructArrayView | Slice
(
const int32 Index, |
Returns a sliced view This is similar to Mid(), but with a narrow contract, i.e. slicing outside of the range of the view is illegal. | |
| void | SliceRangeCheck
(
int32 Index, |
Checks if a slice range [Index, Index+InNum) is in array range. |
Operators
| Type | Name | Description | |
|---|---|---|---|
| FConstStructView | operator[]
(
int32 Index |
Array bracket operator. | |
| FConstStructArrayView & | operator=
(
const FStructArrayView StructArrayView |
Classes
| Type | Name | Description | |
|---|---|---|---|
| FIterator |