MCRO
C++23 utilities for Unreal Engine.
Loading...
Searching...
No Matches
Mcro::TypeInfo::FType Struct Reference

Group together type info for identification. Can have an invalid state when no type is specified. More...

#include <TypeInfo.h>

Data Structures

struct  TTag
 

Public Member Functions

template<typename T >
constexpr FType (TTag< T > &&)
 
constexpr FType ()
 
constexpr FStringView ToString () const
 
FORCEINLINE FString ToStringCopy () const
 
constexpr bool IsValid () const
 
constexpr operator bool () const
 
constexpr bool IsCompatibleWith (FType const &other) const
 check to see if pointers of this and the other types are safe to cast between
 
template<typename Other >
constexpr bool IsCompatibleWith () const
 check to see if pointers of this and the other types are safe to cast between
 
constexpr const FTypeHashbegin () const
 
constexpr const FTypeHashend () const
 
constexpr size_t size () const
 

Data Fields

FStringView Name
 
FTypeHash Hash = 0
 

Static Public Attributes

static constexpr int32 MaxBaseCount = 64
 

Friends

constexpr bool operator== (FType const &left, FType const &right)
 
constexpr bool operator!= (FType const &left, FType const &right)
 
constexpr uint32 GetTypeHash (FType const &self)
 

Detailed Description

Group together type info for identification. Can have an invalid state when no type is specified.

If given type also explicitly list its inheritance (through TInherit for example) base types are also stored for type safety checks.

Definition at line 31 of file TypeInfo.h.

Constructor & Destructor Documentation

◆ FType() [1/2]

template<typename T >
Mcro::TypeInfo::FType::FType ( TTag< T > && )
inlineconstexpr

Definition at line 39 of file TypeInfo.h.

◆ FType() [2/2]

Mcro::TypeInfo::FType::FType ( )
inlineconstexpr

Definition at line 57 of file TypeInfo.h.

Member Function Documentation

◆ begin()

const FTypeHash * Mcro::TypeInfo::FType::begin ( ) const
inlineconstexpr

Definition at line 94 of file TypeInfo.h.

◆ end()

const FTypeHash * Mcro::TypeInfo::FType::end ( ) const
inlineconstexpr

Definition at line 95 of file TypeInfo.h.

◆ IsCompatibleWith() [1/2]

template<typename Other >
bool Mcro::TypeInfo::FType::IsCompatibleWith ( ) const
constexpr

check to see if pointers of this and the other types are safe to cast between

Definition at line 107 of file TypeInfo.h.

◆ IsCompatibleWith() [2/2]

bool Mcro::TypeInfo::FType::IsCompatibleWith ( FType const & other) const
inlineconstexpr

check to see if pointers of this and the other types are safe to cast between

Definition at line 69 of file TypeInfo.h.

◆ IsValid()

bool Mcro::TypeInfo::FType::IsValid ( ) const
inlineconstexpr

Definition at line 65 of file TypeInfo.h.

◆ operator bool()

Mcro::TypeInfo::FType::operator bool ( ) const
inlineconstexpr

Definition at line 66 of file TypeInfo.h.

◆ size()

size_t Mcro::TypeInfo::FType::size ( ) const
inlineconstexpr

Definition at line 96 of file TypeInfo.h.

◆ ToString()

FStringView Mcro::TypeInfo::FType::ToString ( ) const
inlineconstexpr

Definition at line 62 of file TypeInfo.h.

◆ ToStringCopy()

FORCEINLINE FString Mcro::TypeInfo::FType::ToStringCopy ( ) const
inline

Definition at line 63 of file TypeInfo.h.

Friends And Related Symbol Documentation

◆ GetTypeHash

uint32 GetTypeHash ( FType const & self)
friend

Definition at line 89 of file TypeInfo.h.

◆ operator!=

bool operator!= ( FType const & left,
FType const & right )
friend

Definition at line 87 of file TypeInfo.h.

◆ operator==

bool operator== ( FType const & left,
FType const & right )
friend

Definition at line 86 of file TypeInfo.h.

Field Documentation

◆ Hash

FTypeHash Mcro::TypeInfo::FType::Hash = 0

Definition at line 60 of file TypeInfo.h.

◆ MaxBaseCount

int32 Mcro::TypeInfo::FType::MaxBaseCount = 64
staticconstexpr

Definition at line 33 of file TypeInfo.h.

◆ Name

FStringView Mcro::TypeInfo::FType::Name

Definition at line 59 of file TypeInfo.h.


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