Navigation
API > API/Runtime > API/Runtime/Core
Optimized representation of a case-sensitive string, as used by localization keys. This references an entry within a internal table to avoid memory duplication, as well as offering optimized comparison and hashing performance.
| Name | FTextKey |
| Type | class |
| Header File | /Engine/Source/Runtime/Core/Public/Internationalization/TextKey.h |
| Include Path | #include "Internationalization/TextKey.h" |
Syntax
class FTextKey
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
| Internationalization/TextKey.h | |||
FTextKey
(
FStringView InStr |
Internationalization/TextKey.h | ||
FTextKey () |
Internationalization/TextKey.h | ||
FTextKey
(
const TCHAR* InStr |
Internationalization/TextKey.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| Index | int32 | Index of the internal FKeyData we reference | Internationalization/TextKey.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void AppendString
(
FStringBuilderBase& Out |
Internationalization/TextKey.h | ||
void AppendString
(
FString& Out |
Internationalization/TextKey.h | ||
const TCHAR * GetChars() |
Get the underlying chars buffer this text key represents | Internationalization/TextKey.h | |
bool IsEmpty() |
Is this text key empty? | Internationalization/TextKey.h | |
void Reset() |
Reset this text key to be empty | Internationalization/TextKey.h | |
void SerializeAsString
(
FArchive& Ar |
Serialize this text key as if it were an FString | Internationalization/TextKey.h | |
void SerializeAsString
(
FStructuredArchiveSlot Slot |
Serialize this text key as if it were an FString | Internationalization/TextKey.h | |
void SerializeDiscardHash
(
FArchive& Ar |
Serialize this text key including its hash value, discarding the hash on load (to upgrade from an older hashing algorithm) | Internationalization/TextKey.h | |
void SerializeDiscardHash
(
FStructuredArchiveSlot Slot |
Serialize this text key including its hash value, discarding the hash on load (to upgrade from an older hashing algorithm) | Internationalization/TextKey.h | |
void SerializeWithHash
(
FArchive& Ar |
Serialize this text key including its hash value (this method is sensitive to hashing algorithm changes, so only use it for generated files that can be rebuilt from another source) | Internationalization/TextKey.h | |
void SerializeWithHash
(
FStructuredArchiveSlot Slot |
Serialize this text key including its hash value (this method is sensitive to hashing algorithm changes, so only use it for generated files that can be rebuilt from another source) | Internationalization/TextKey.h | |
| Internationalization/TextKey.h | |||
| Convert this text key back to its string representation | Internationalization/TextKey.h | ||
void ToString
(
FStringBuilderBase& Out |
Internationalization/TextKey.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static void CompactDataStructures() |
Compact any slack within the internal table | Internationalization/TextKey.h | |
static void TearDown() |
Do not use any FTextKey or FTextId after calling this | Internationalization/TextKey.h |