Apparatus Version 1.8
ECS data-oriented workflow for Unreal Engine.
Public Member Functions | List of all members
TFingerprint< Ts > Struct Template Reference

The templated traits/details fingerprint. More...

#include <Fingerprint.h>

Inheritance diagram for TFingerprint< Ts >:
Inheritance graph
[legend]
Collaboration diagram for TFingerprint< Ts >:
Collaboration graph
[legend]

Public Member Functions

 TFingerprint (const EBootFilter InBootState=EBootFilter::None)
 Construct a fingerprint with an optional boot state. More...
 
- Public Member Functions inherited from FFingerprint
EBootFilter GetBootState () const
 Get the active boot state. More...
 
EApparatusStatus SetBootState (const EBootFilter InBootState)
 Set the new active boot state. More...
 
EApparatusStatus SetBooted (bool bState=true)
 Set the new active boot state. More...
 
bool IsBooted () const
 Check if the fingerprint corresponds to a booted entity. More...
 
const TraitsTypeGetTraits () const
 Get the traits of the fingerprint. More...
 
const DetailsTypeGetDetails () const
 Get the details of the fingerprint. More...
 
int32 TraitsNum () const
 The number of traits in the fingerprint. More...
 
int32 DetailsNum () const
 The number of details in the fingerprint. More...
 
const FTraitmarkGetTraitmark () const
 Get the traitmark part of the fingerprint. More...
 
const FDetailmarkGetDetailmark () const
 Get the detailmark part of the fingerprint. More...
 
 operator const FTraitmark & () const
 Convert a fingerprint to a traitmark. More...
 
 operator const FDetailmark & () const
 Convert a fingerprint to a detailmark. More...
 
const FBitMaskGetTraitsMask () const
 Get the traits mask of the fingerprint. More...
 
const FBitMaskGetDetailsMask () const
 Get the details mask of the fingerprint. More...
 
UScriptStruct * TraitAt (const int32 Index) const
 Get a trait by its index. More...
 
TSubclassOf< UDetailDetailAt (const int32 Index) const
 Get a detail by its index. More...
 
 operator TArray< TSubclassOf< UDetail >> () const
 Convert to an array of detail types. More...
 
 operator bool () const
 Check if a fingerprint is viable and has any effect. More...
 
EApparatusStatus FindDetailsMappingFrom (const TArray< TSubclassOf< UDetail >> &InDetailClasses, TArray< int32 > &OutMapping) const
 Get an indexing mapping from another fingerprint defined by an array of details. More...
 
void FindTraitsMappingFrom (const TArray< UScriptStruct * > &InTraitmark, TArray< int32 > &OutMapping) const
 Get an indexing mapping from another traitmark defined by an array of traits. More...
 
EApparatusStatus FindDetailsMappingFrom (const TArray< TSubclassOf< UDetail >> &InDetailClasses, TArray< TArray< int32 >> &OutMapping) const
 Get an indexing multi-mapping from another fingerprint defined by an array of details. More...
 
EApparatusStatus FindDetailsMappingFrom (const FFingerprint &Fingerprint, TArray< int32 > &OutMapping) const
 Get an indexing mapping from another fingerprint. More...
 
EApparatusStatus FindTraitsMappingFrom (const FFingerprint &Fingerprint, TArray< int32 > &OutMapping) const
 Get an indexing mapping from another fingerprint's traits. More...
 
EApparatusStatus FindTraitsMappingFrom (const FTraitmark &InTraitmark, TArray< int32 > &OutMapping) const
 Get an indexing mapping from another traitmark's traits. More...
 
EApparatusStatus FindDetailsMappingTo (const FFingerprint &Fingerprint, TArray< int32 > &OutMapping) const
 Get an indexing details mapping to another fingerprint. More...
 
EApparatusStatus FindTraitsMappingTo (const FTraitmark &InTraitmark, TArray< int32 > &OutMapping) const
 Get an indexing traits mapping to another traitmark. More...
 
EApparatusStatus FindTraitsMappingTo (const FFingerprint &InFingerprint, TArray< int32 > &OutMapping) const
 Get an indexing traits mapping to another traitmark. More...
 
EApparatusStatus FindDetailsMappingFrom (const FFingerprint &Fingerprint, TArray< TArray< int32 >> &OutMapping) const
 Get a detail indexing multi-mapping from another fingerprint. More...
 
EApparatusStatus FindDetailsMappingTo (const FFingerprint &Fingerprint, TArray< TArray< int32 >> &OutMapping) const
 Get an indexing multi-mapping to another fingerprint. More...
 
bool Matches (const FFilter &Filter) const
 Check if the fingerprint matches a filter. More...
 
bool Matches (const FFingerprint &Fingerprint) const
 Check if the fingerprint matches another fingerprint acting as a filter. More...
 
bool Matches (const struct FTraitmark &InTraitmark) const
 Check if the fingerprint matches a traitmark acting as a filter. More...
 
bool Matches (const struct FDetailmark &InDetailmark) const
 Check if the fingerprint matches a detailmark acting as a filter. More...
 
int32 IndexOf (UScriptStruct *TraitType) const
 Get the index of a specific trait type. More...
 
int32 IndexOf (const TSubclassOf< UDetail > DetailClass) const
 Get the index of a specific detail class. More...
 
EApparatusStatus IndicesOf (const TSubclassOf< UDetail > DetailClass, TArray< int32 > &OutIndices) const
 Get the indices of a specific detail class. More...
 
EApparatusStatus SetTraitmark (FTraitmark &&InTraitmark)
 Move a traitmark to the fingerprint's traitmark. More...
 
EApparatusStatus SetTraitmark (const FTraitmark &InTraitmark)
 Set the fingerprint's traitmark equal to a traitmark. More...
 
EApparatusStatus SetDetailmark (FDetailmark &&InDetailmark)
 Move a detailmark to the fingerprint's detailmark. More...
 
EApparatusStatus SetDetailmark (const FDetailmark &InDetailmark)
 Set the fingerprint's detailmark equal to a detailmark. More...
 
EApparatusStatus Set (FTraitmark &&InTraitmark)
 Move a traitmark to the fingerprint. More...
 
EApparatusStatus Set (const FTraitmark &InTraitmark)
 Set the fingerprint equal to a traitmark. More...
 
EApparatusStatus Set (FDetailmark &&InDetailmark)
 Move a detailmark to the fingerprint. More...
 
EApparatusStatus Set (const FDetailmark &InDetailmark)
 Set the fingerprint equal to a detailmark. More...
 
EApparatusStatus Set (FFingerprint &&InFingerprint)
 Move a fingerprint to this one. More...
 
EApparatusStatus Set (const FFingerprint &InFingerprint)
 Set a fingerprint equal to another fingerprint. More...
 
template<typename TAllocator >
EApparatusStatus Set (const TArray< UScriptStruct *, TAllocator > &InTraits, const EBootFilter InBootState)
 Set a fingerprint to an array of traits and a boot state. More...
 
template<typename TAllocator >
EApparatusStatus Set (const TArray< TSubclassOf< UDetail >, TAllocator > &InDetailClasses, const EBootFilter InBootState)
 Set a fingerprint to an array of detail classes and a boot state. More...
 
template<typename TAllocator >
EApparatusStatus Set (const TArray< UDetail *, TAllocator > &InDetails, const EBootFilter InBootState)
 Set a fingerprint to an array of active details and a boot state. More...
 
FFingerprintoperator= (FTraitmark &&InTraitmark)
 Move a traitmark to the fingerprint. More...
 
FFingerprintoperator= (const FTraitmark &InTraitmark)
 Set the fingerprint equal to a traitmark. More...
 
FFingerprintoperator= (FDetailmark &&InDetailmark)
 Move a detailmark to the fingerprint. More...
 
FFingerprintoperator= (const FDetailmark &InDetailmark)
 Set the fingerprint equal to a detailmark. More...
 
FFingerprintoperator= (FFingerprint &&Fingerprint)
 Move a fingerprint to this one. More...
 
FFingerprintoperator= (const FFingerprint &Fingerprint)
 Set the fingerprint equal to another fingerprint. More...
 
template<typename TAllocator >
FFingerprintoperator= (const TArray< UScriptStruct *, TAllocator > &InTraitTypes)
 Set a fingerprint equal to an array of trait types. More...
 
template<typename TAllocator >
FFingerprintoperator= (const TArray< TSubclassOf< UDetail >, TAllocator > &InDetailClasses)
 Set a fingerprint equal to an array of detail classes. More...
 
template<typename TAllocator >
FFingerprintoperator= (const TArray< UDetail *, TAllocator > &InDetails)
 Set a fingerprint equal to an array of details. More...
 
EApparatusStatus Add (std::initializer_list< UScriptStruct * > TraitTypes)
 Add trait types to a fingerprint. More...
 
EApparatusStatus Add (std::initializer_list< TSubclassOf< UDetail >> DetailClasses)
 Add detail classes to a fingerprint. More...
 
EApparatusStatus Add (const FFingerprint &Fingerprint, const EBootFilter InBootState=EBootFilter::None)
 Add a fingerprint with a boot state override. More...
 
EApparatusStatus Add (UScriptStruct *TraitType, const EBootFilter InBootState=EBootFilter::None)
 Add a trait type. More...
 
EApparatusStatus Add (const TSubclassOf< UDetail > DetailClass, const EBootFilter InBootState=EBootFilter::None)
 Add a detail class. More...
 
template<typename TAllocator >
EApparatusStatus Add (const TArray< UScriptStruct *, TAllocator > &InTraitTypes, const EBootFilter InBootState=EBootFilter::None)
 Add an array of traits and a boot state specification. More...
 
template<typename TAllocator >
EApparatusStatus Add (const TArray< TSubclassOf< UDetail >, TAllocator > &DetailClasses, const EBootFilter InBootState=EBootFilter::None)
 Add an arrary of detail classes. More...
 
template<typename TAllocator >
EApparatusStatus Add (const TArray< UDetail *, TAllocator > &InDetails, const EBootFilter InBootState=EBootFilter::None)
 Add an array of details and a boot state specification. More...
 
template<typename T >
EApparatusStatus AddTrait ()
 Add a trait type. More...
 
template<class T >
EApparatusStatus AddDetail ()
 Add a detail class. More...
 
template<class ... Ts>
EApparatusStatus Add ()
 Add component(s) to a fingerprint. More...
 
FFingerprintoperator+= (std::initializer_list< UScriptStruct * > TraitTypes)
 Add variadic trait types. More...
 
FFingerprintoperator+= (std::initializer_list< TSubclassOf< UDetail >> DetailClasses)
 Add variadic detail classes. More...
 
FFingerprintoperator+= (const FFingerprint &Fingerprint)
 Add a fingerprint specification. More...
 
template<typename TAllocator >
FFingerprintoperator+= (const TArray< UScriptStruct *, TAllocator > &TraitTypes)
 Add an array of trait types. More...
 
template<typename TAllocator >
FFingerprintoperator+= (const TArray< TSubclassOf< UDetail >, TAllocator > &DetailClasses)
 Add an array of detail classes. More...
 
template<typename TAllocator >
FFingerprintoperator+= (const TArray< UDetail *, TAllocator > &InDetails)
 Add active details from an array. More...
 
FFingerprintoperator+= (UScriptStruct *TraitType)
 Add a single trait type. More...
 
FFingerprintoperator+= (TSubclassOf< UDetail > DetailClass)
 Add a single detail class. More...
 
EApparatusStatus Remove (UScriptStruct *const TraitType)
 Remove a trait type from the fingerprint specification. More...
 
EApparatusStatus Remove (const TSubclassOf< UDetail > DetailClass)
 Remove a detail class from the fingerprint specification. More...
 
template<typename T >
EApparatusStatus RemoveTrait ()
 Remove a trait type from a fingerprint. More...
 
template<class D >
EApparatusStatus RemoveDetail ()
 Remove a detail class from a fingerprint. More...
 
template<class ... Cs>
EApparatusStatus Remove ()
 Remove component(s) from the fingerprint. More...
 
FFingerprintoperator-= (UScriptStruct *const TraitType)
 Remove a trait type from the fingerprint. More...
 
FFingerprintoperator-= (TSubclassOf< UDetail > DetailClass)
 Remove a detail class from a fingerprint. More...
 
bool Contains (const UScriptStruct *const TraitType) const
 Check whether a fingerprint contains a trait specification. More...
 
bool Contains (const TSubclassOf< UDetail > DetailClass) const
 Check whether a fingerprint contains a detail specification. More...
 
template<typename T >
bool ContainsTrait () const
 Check whether a fingerprint contains a trait specification. More...
 
template<class D >
bool ContainsDetail () const
 Check whether a fingerprint contains a detail specification. More...
 
template<typename ... Ts>
bool Contains () const
 Check whether a fingerprint contains a component specification. More...
 
bool Contains (const FFingerprint &InFingerprint) const
 Check if the fingerprint fully includes another fingerprint. More...
 
EApparatusStatus Reset (const EBootFilter InBootState=EBootFilter::None)
 Clear the fingerprint without any deallocations. More...
 
FString ToString () const
 Convert a fingerprint to a string. More...
 
uint32 CalcHash () const
 Calculate the hash sum of the fingerprint. More...
 
 FFingerprint (const EBootFilter InBootState=EBootFilter::None)
 Construct an empty fingerprint with an optional boot state. More...
 
 FFingerprint (const TSubclassOf< UDetail > DetailClass, const EBootFilter InBootState=EBootFilter::None)
 Construct a new fingerprint from a single detail class and an optional boot state. More...
 
 FFingerprint (UScriptStruct *TraitType, const EBootFilter InBootState=EBootFilter::None)
 Construct a new fingerprint from a single trait type and an optional boot state. More...
 
template<typename TAllocator >
 FFingerprint (const TArray< UDetail *, TAllocator > &InDetailClasses, const EBootFilter InBootState=EBootFilter::None)
 Construct a fingerprint from an array of details and an optional boot state. More...
 
template<typename TAllocator >
 FFingerprint (const TArray< TSubclassOf< UDetail >, TAllocator > &InDetailClasses, const EBootFilter InBootState=EBootFilter::None)
 Construct a fingerprint from an array of detail classes and an optional boot state. More...
 
template<typename TAllocatorA , typename TAllocatorB >
 FFingerprint (const TArray< UScriptStruct *, TAllocatorA > &InTraitTypes, const TArray< TSubclassOf< UDetail >, TAllocatorB > &InDetailClasses, const EBootFilter InBootState=EBootFilter::None)
 Construct a fingerprint from arrays of detail classes and trait types and also an optional boot state. More...
 
 FFingerprint (std::initializer_list< UScriptStruct * > InTraitTypes, std::initializer_list< TSubclassOf< UDetail >> InDetailClasses, const EBootFilter InBootState=EBootFilter::None)
 Construct a fingerprint from initializer lists of trait types and detail classes and also an optional boot state. More...
 
 FFingerprint (const FFingerprint &InFingerprint)
 Construct a fingerprint as a copy of another one. More...
 
 FFingerprint (FFingerprint &&InFingerprint)
 Move-construct a new fingerprint. More...
 
template<typename ... Ts>
 FFingerprint (TFingerprint< Ts... > &&InFingerprint)
 Move-construct from a templated fingerprint. More...
 
 FFingerprint (FTraitmark &&InTraitmark, FDetailmark &InDetailmark)
 Construct a new fingerprint while moving a traitmark and a detailmark. More...
 

Additional Inherited Members

- Public Types inherited from FFingerprint
typedef FTraitmark::TraitsType TraitsType
 The type of traits array. More...
 
typedef FDetailmark::DetailsType DetailsType
 The type of details array. More...
 
- Static Public Member Functions inherited from FFingerprint
template<typename ... Ts>
static FFingerprint Make (const EBootFilter InBootState=EBootFilter::None)
 Make a fingerprint with components and an optional boot filter. More...
 
- Static Public Attributes inherited from FFingerprint
static const FFingerprint Zero
 The all-zeroed fingerprint. More...
 
static const FFingerprint Halted
 The default fingerprint for newly spanwed subjects. More...
 

Detailed Description

template<typename ... Ts>
struct TFingerprint< Ts >

The templated traits/details fingerprint.

Template Parameters
TsThe types of components to use.

Constructor & Destructor Documentation

◆ TFingerprint()

template<typename ... Ts>
TFingerprint< Ts >::TFingerprint ( const EBootFilter  InBootState = EBootFilter::None)
inline

Construct a fingerprint with an optional boot state.


The documentation for this struct was generated from the following file: