class
HString
String handle.
Provides a wrapper around an Unicode string, primarily for localization purposes.
Actual value for this string is looked up in a global string table based on the provided identifier string and currently active language. If such value doesn't exist then the identifier is used as is.
Use {0}, {1}, etc. in the string value for values that might change dynamically.
Public
Constructors
HString
Creates a new localized string with the specified identifier.
If the identifier doesn't previously exist in the string table, identifier value will also be used for initializing the default language version of the string.
- identifier
- String you can use for later referencing the localized string.
- stringTableId
- Unique identifier of the string table to retrieve the string from.
HString
Creates a new localized string with the specified identifier and sets the default language version of the string.
If a string with that identifier already exists default language string will be updated.
- identifier
- String you can use for later referencing the localized string.
- defaultString
- Default string to assign to the specified identifier. Language to which it will be assigned depends on the StringTable::DEFAULT_LANGUAGE value.
- stringTableId
- Unique identifier of the string table to retrieve the string from.
HString
Creates a new empty localized string.
- stringTableId
- Unique identifier of the string table to retrieve the string from.
HString
Creates a new empty localized string.
HString
Methods
~HString
GetValue
SetParameter
Sets a value of a string parameter.
Parameters are specified as bracketed values within the string itself (for example {0}, {1}) etc. Use ^ as an escape character.
- index
- Index of the parameter to set.
- value
- Value to assign to the parameter.