Ark Server API (ASA) - Wiki
|
#include <NameTypes.h>
Static Public Attributes | |
static constexpr uint32 | StringBufferSize = NAME_SIZE + 1 + 10 |
Private Attributes | |
FNameEntryId | ComparisonIndex |
uint32 | Number |
Public name, available to the world. Names are stored as a combination of an index into a table of unique strings and an instance number. Names are case-insensitive, but case-preserving (when WITH_CASE_PRESERVING_NAME is 1)
Definition at line 600 of file NameTypes.h.
|
inline |
Create an FName with a hardcoded string index.
N | The hardcoded value the string portion of the name will have. The number portion will be NAME_NO_NUMBER |
Definition at line 916 of file NameTypes.h.
|
inline |
Create an FName with a hardcoded string index and (instance).
N | The hardcoded value the string portion of the name will have |
InNumber | The hardcoded value for the number portion of the name |
Definition at line 924 of file NameTypes.h.
|
inline |
Create an FName from an existing string, but with a different instance.
Other | The FName to take the string values from |
InNumber | The hardcoded value for the number portion of the name |
Definition at line 936 of file NameTypes.h.
|
inline |
Create an FName from its component parts Only call this if you really know what you're doing
Definition at line 945 of file NameTypes.h.
|
inline |
Default constructor, initialized to None
Definition at line 974 of file NameTypes.h.
|
inlineexplicit |
Scary no init constructor, used for something obscure in UObjectBase
Definition at line 984 of file NameTypes.h.
|
explicit |
Definition at line 1565 of file NameTypes.h.
|
explicit |
Definition at line 1574 of file NameTypes.h.
FORCEINLINE FName::FName | ( | FMemoryImageName | InName | ) |
Definition at line 1583 of file NameTypes.h.
Create an FName. If FindType is FNAME_Find, and the name doesn't already exist, then the name will be NAME_None. The check for existance or not depends on UE_FNAME_OUTLINE_NUMBER. When UE_FNAME_OUTLINE_NUMBER is 0, we only check for the string part. When UE_FNAME_OUTLINE_NUMBER is 1, we check for whole name including the number.
Name | Value for the string portion of the name |
FindType | Action to take (see EFindName) |
Create FName from non-null string with known length
|
inlineexplicit |
|
inlineexplicit |
|
inlineexplicit |
Create an FName. Will add the string to the name table if it does not exist. When UE_FNAME_OUTLINE_NUMBER is set, will also add the combination of base string and number to the name table if it doesn't exist.
Name | Value for the string portion of the name |
Number | Value for the number portion of the name |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Create an FName. If FindType is FNAME_Find, and the string part of the name doesn't already exist, then the name will be NAME_None
Name | Value for the string portion of the name |
Number | Value for the number portion of the name |
FindType | Action to take (see EFindName) |
bSplitName | true if the trailing number should be split from the name when Number == NAME_NO_NUMBER_INTERNAL, or false to always use the name as-is |
FName::FName | ( | const FNameEntrySerialized & | LoadedEntry | ) |
Add/remove an exemption to the formatting applied by NameToDisplayString. Example: exempt the compound word "MetaHuman" to ensure its not reformatted as "Meta Human".
Converts an FName to a readable format, in place, appending to an existing string (ala GetFullName)
Out | String to append with the string representation of the name |
void FName::AppendString | ( | FUtf8StringBuilderBase & | Out | ) | const |
void FName::AppendString | ( | FWideStringBuilderBase & | Out | ) | const |
Converts an FName to a readable format, in place, appending to an existing string (ala GetFullName)
Out | StringBuilder to append with the string representation of the name |
|
private |
Compares name to passed in one. Sort is alphabetical ascending.
Other | Name to compare this against |
|
inline |
Fast non-alphabetical order that is only stable during this process' lifetime.
Other | Name to compare this against |
Definition at line 897 of file NameTypes.h.
|
inlinestatic |
Only call this if you really know what you're doing
Definition at line 959 of file NameTypes.h.
|
inlinestaticprivate |
|
inlinestaticprivate |
Definition at line 1322 of file NameTypes.h.
|
static |
|
static |
|
inline |
Fast non-alphabetical order that is only stable during this process' lifetime.
Definition at line 773 of file NameTypes.h.
|
inlinestatic |
|
inline |
|
inlineprivate |
const FNameEntry * FName::GetComparisonNameEntry | ( | ) | const |
|
inline |
Definition at line 613 of file NameTypes.h.
|
inlineprivate |
|
inlineprivate |
Definition at line 1280 of file NameTypes.h.
const FNameEntry * FName::GetDisplayNameEntry | ( | ) | const |
|
static |
|
static |
|
inline |
void FName::GetPlainANSIString | ( | ANSICHAR(&) | AnsiName[NAME_SIZE] | ) | const |
Copy ANSI name without number part. Must only be used for ANSI FNames. Doesn't allocate.
Get name without number part as a dynamically allocated string
Definition at line 637 of file NameTypes.h.
uint32 FName::GetPlainNameString | ( | TCHAR(&) | OutName[NAME_SIZE] | ) | const |
Convert name without number part into TCHAR buffer and returns string length. Doesn't allocate.
Copy wide name without number part. Must only be used for wide FNames. Doesn't allocate.
uint32 FName::GetStringLength | ( | ) | const |
Get the number of characters, excluding null-terminator, that ToString() would yield
FORCEINLINE bool FName::IsEqual | ( | const FName & | Other, |
const ENameCase | CompareMethod = ENameCase::IgnoreCase, | ||
const bool | bCompareNumber = true ) const |
Check to see if this FName matches the other FName, potentially also checking for any case variations
Definition at line 1641 of file NameTypes.h.
|
inline |
True for FName(), FName(NAME_None) and FName("None")
Definition at line 785 of file NameTypes.h.
|
inline |
Paranoid sanity check
All FNames are valid except for stomped memory, dangling pointers, etc. Should only be used to investigate such bugs and not in production code.
Definition at line 800 of file NameTypes.h.
Takes an FName and checks to see that it follows the rules that Unreal requires for package or group names.
OutReason | If the check fails, this string is filled in with the reason why. |
bIsGroupName | if true, check legality for a group name, else check legality for a package name |
Definition at line 868 of file NameTypes.h.
|
inline |
Paranoid sanity check, same as IsValid()
Definition at line 803 of file NameTypes.h.
Takes an FName and checks to see that it follows the rules that Unreal requires for object names.
OutReason | If the check fails, this string is filled in with the reason why. |
Definition at line 855 of file NameTypes.h.
|
static |
Checks to see that a given name-like string follows the rules that Unreal requires.
InName | String containing the name to test. |
InInvalidChars | The set of invalid characters that the name cannot contain. |
OutReason | If the check fails, this string is filled in with the reason why. |
InErrorCtx | Error context information to show in the error message (default is "Name"). |
|
inline |
Checks to see that a FName follows the rules that Unreal requires.
InInvalidChars | The set of invalid characters that the name cannot contain |
OutReason | If the check fails, this string is filled in with the reason why. |
InErrorCtx | Error context information to show in the error message (default is "Name"). |
Definition at line 830 of file NameTypes.h.
|
static |
|
static |
|
static |
|
inline |
Takes an FName and checks to see that it follows the rules that Unreal requires.
OutReason | If the check fails, this string is filled in with the reason why. |
InInvalidChars | The set of invalid characters that the name cannot contain |
Definition at line 843 of file NameTypes.h.
|
staticprivate |
|
inline |
Slow alphabetical order that is stable / deterministic over process runs.
Definition at line 779 of file NameTypes.h.
|
static |
Takes a string and breaks it down into a human readable string. For example - "bCreateSomeStuff" becomes "Create Some Stuff?" and "DrawScale3D" becomes "Draw Scale 3D".
InDisplayName | [In, Out] The name to sanitize |
bIsBool | True if the name is a bool |
Inequality operator.
Other | String to compare this name to |
Definition at line 1140 of file NameTypes.h.
FORCEINLINE bool FName::operator!= | ( | EName | Ename | ) | const |
Definition at line 1668 of file NameTypes.h.
|
inline |
Definition at line 750 of file NameTypes.h.
Equality operator.
Other | String to compare this name to |
FORCEINLINE bool FName::operator== | ( | EName | Ename | ) | const |
Definition at line 1636 of file NameTypes.h.
|
inline |
Definition at line 745 of file NameTypes.h.
|
staticprivate |
|
staticprivate |
|
static |
|
inline |
Definition at line 630 of file NameTypes.h.
Tear down system and free all allocated memory
FName must not be used after teardown
|
inline |
Converts an FName to a readable format
Definition at line 662 of file NameTypes.h.
Converts an FName to a readable format, in place
Out | String to fill with the string representation of the name |
Definition at line 678 of file NameTypes.h.
void FName::ToString | ( | FUtf8StringBuilderBase & | Out | ) | const |
void FName::ToString | ( | FWideStringBuilderBase & | Out | ) | const |
Converts an FName to a readable format, in place
Out | StringBuilder to fill with the string representation of the name |
Convert to string buffer to avoid dynamic allocations and returns string length
Fails hard if OutLen < GetStringLength() + 1. StringBufferSize guarantees success.
Note that a default constructed FName returns "None" instead of ""
Definition at line 711 of file NameTypes.h.
|
inline |
Returns an integer that compares equal in the same way FNames do, only usable within the current process
Definition at line 1226 of file NameTypes.h.
bool FName::TryAppendAnsiString | ( | FAnsiStringBuilderBase & | Out | ) | const |
Converts an ANSI FName to a readable format appended to the string builder.
Out | A string builder to write the readable representation of the name into. |
|
inline |
Definition at line 1254 of file NameTypes.h.
|
friend |
Definition at line 1383 of file NameTypes.h.
|
friend |
Definition at line 1658 of file NameTypes.h.
|
friend |
Definition at line 1663 of file NameTypes.h.
Inequality operator with CharType* on left hand side and FName on right hand side
Definition at line 1348 of file NameTypes.h.
|
friend |
Definition at line 1422 of file NameTypes.h.
|
friend |
Definition at line 1392 of file NameTypes.h.
|
friend |
Definition at line 1418 of file NameTypes.h.
|
friend |
Definition at line 1397 of file NameTypes.h.
|
friend |
Definition at line 1410 of file NameTypes.h.
|
friend |
Definition at line 1406 of file NameTypes.h.
Equality operator with CharType* on left hand side and FName on right hand side
Definition at line 1335 of file NameTypes.h.
|
friend |
Definition at line 1414 of file NameTypes.h.
|
friend |
Definition at line 1388 of file NameTypes.h.
|
friend |
Definition at line 1379 of file NameTypes.h.
|
friend |
Definition at line 1371 of file NameTypes.h.
|
friend |
Definition at line 1375 of file NameTypes.h.
|
friend |
Definition at line 1402 of file NameTypes.h.
|
private |
Index into the Names array (used to find String portion of the string/number pair used for comparison)
Definition at line 1240 of file NameTypes.h.
|
private |
Number portion of the string/number pair (stored internally as 1 more than actual, so zero'd memory will be the default, no-instance case)
Definition at line 1243 of file NameTypes.h.
Buffer size required for any null-terminated FName string, i.e. [name] '_' [digits] '\0'
Definition at line 699 of file NameTypes.h.