Module |
|
Header |
/Engine/Plugins/Experimental/GeometryProcessing/Source/GeometricObjects/Public/Util/SparseIndexCollectionTypes.h |
Include |
#include "Util/SparseIndexCollectionTypes.h" |
struct FOptionallySparseIndexMap
Index map that supports dense or sparse storage, or a simple formula-based map (e.g. constant, identity, shift) For dense and sparse, the formula can be used to set default values.
Name | Description | ||
---|---|---|---|
|
int |
DefaultOffset |
Mapping to assign defaults for indices that are not explicitly assigned; computed as Index*DefaultScale + DefaultOffset |
|
int |
DefaultScale |
|
|
TArray< int > |
Dense |
Storage used when map is dense |
|
MapType |
Choice of storage backing the map |
|
|
int |
MaxIndex |
Max index in map; -1 will leave the map unbounded (invalid for Dense maps) |
|
TMap< int, int ... |
Sparse |
Storage used when map is sparse |
Name | Description | |
---|---|---|
|
FOptionallySparseIndexMap() |
Default constructor sets map to sparse, w/ constant -1 default value |
|
FOptionallySparseIndexMap ( |
Construct map with explicit choice of storage type |
|
FOptionallySparseIndexMap ( |
Construct map with dense storage copied from an existing array |
|
FOptionallySparseIndexMap ( |
Construct map with automatically-chosen dense or sparse storage, based on max index and estimated element count |
Name | Description | ||
---|---|---|---|
|
BadIndex ( |
||
|
FOptionallyS... |
ConstantMap ( |
|
|
Contains ( |
Dense variant: returns true unless you have set index to InvalidIndex (eg via SetToInvalid) sparse variant: returns true if index is in map or default index is >= 0 scaleandoffset variant: returns true if default index is >= 0 all return false if index is out-of-bounds |
|
|
FOptionallyS... |
IdentityMap ( |
|
|
InitDefaults() |
Initialize default values for dense map (sparse defaults are computed on the fly) |
|
|
Initialize ( |
Automatically choose sparse or dense storage based on use estimate |
|
|
Set ( |
Sets the map at a given index. Do not call if MapType is ScaleAndOffset. |
|
|
SetInvalid ( |
||
|
FOptionallyS... |
SparseIdentityMap ( |
|
|
Unset ( |
Name | Description | ||
---|---|---|---|
|
const int |
operator[] ( |
Array-style accessor to the map |
Name |
Description |
|
---|---|---|
|
EMapType |
Different kinds of storage that could be used for the map |