Ark Server API (ASA) - Wiki
|
#include <StringFormatter.h>
Public Member Functions | |
FStringFormatter () | |
FString | Format (const TCHAR *InExpression, const TMap< FString, FStringFormatArg > &InArgs) const |
FString | Format (const TCHAR *InExpression, const TArray< FStringFormatArg > &InArgs) const |
TValueOrError< FString, FExpressionError > | FormatStrict (const TCHAR *InExpression, const TMap< FString, FStringFormatArg > &InArgs) const |
TValueOrError< FString, FExpressionError > | FormatStrict (const TCHAR *InExpression, const TArray< FStringFormatArg > &InArgs) const |
Private Member Functions | |
TValueOrError< FString, FExpressionError > | FormatInternal (const TCHAR *InExpression, const TMap< FString, FStringFormatArg > &InArgs, bool bStrict) const |
TValueOrError< FString, FExpressionError > | FormatInternal (const TCHAR *InExpression, const TArray< FStringFormatArg > &InArgs, bool bStrict) const |
Private Attributes | |
FTokenDefinitions | NamedDefinitions |
FTokenDefinitions | OrderedDefinitions |
FTokenDefinitions | StrictNamedDefinitions |
FTokenDefinitions | StrictOrderedDefinitions |
A string formatter is responsible for formatting string patterns using a set of named, or ordered arguments
Definition at line 18 of file StringFormatter.h.
FStringFormatter::FStringFormatter | ( | ) |
|
inline |
Format the specified string using the specified arguments. Replaces instances of {0} with indices from the given array matching the index specified in the token
InExpression | A string representing the format expression |
InArgs | An array of ordered arguments that match the tokens specified in InExpression |
Definition at line 47 of file StringFormatter.h.
|
inline |
Format the specified string using the specified arguments. Replaces instances of { Argument } with keys in the map matching 'Argument'
InExpression | A string representing the format expression |
InArgs | A map of named arguments that match the tokens specified in InExpression |
Definition at line 30 of file StringFormatter.h.
|
private |
|
private |
Internal formatting logic
|
inline |
Format the specified string using the specified arguments. Replaces instances of {0} with indices from the given array matching the index specified in the token
InExpression | A string representing the format expression |
InArgs | An array of ordered arguments that match the tokens specified in InExpression |
Definition at line 75 of file StringFormatter.h.
|
inline |
Format the specified string using the specified arguments. Replaces instances of { Argument } with keys in the map matching 'Argument'
InExpression | A string representing the format expression |
InArgs | A map of named arguments that match the tokens specified in InExpression |
Definition at line 64 of file StringFormatter.h.
|
private |
Token definitions for lenient lexers
Definition at line 87 of file StringFormatter.h.
|
private |
Definition at line 88 of file StringFormatter.h.
|
private |
Token definitions for strict lexers
Definition at line 91 of file StringFormatter.h.
|
private |
Definition at line 92 of file StringFormatter.h.