PixelLightAPI
.
|
Localization group. More...
#include <LocalizationGroup.h>
Public Member Functions | |
String | GetName () const |
Returns the name of the group. | |
String | GetFromLanguage () const |
Returns the language used as 'from-key'. | |
void | SetFromLanguage (const String &sFrom=English) |
Sets the language used as 'from-key'. | |
String | GetToLanguage () const |
Returns the language used as 'to-key'. | |
void | SetToLanguage (const String &sTo=English) |
Sets the language used as 'to-key'. | |
uint32 | GetNumOfTexts () const |
Returns the number of texts. | |
LocalizationText * | GetText (uint32 nIndex) const |
Returns a text by index. | |
LocalizationText * | GetText (const String &sName) const |
Returns a text by name. | |
PLCORE_API LocalizationText * | AddText (const String &sName, const String &sTranslation) |
Adds a new text. | |
PLCORE_API bool | RemoveText (uint32 nIndex) |
Removes a text by index. | |
PLCORE_API bool | RemoveText (const String &sName) |
Removes a text by name. | |
PLCORE_API void | RemoveAllTexts () |
Removes all texts. | |
virtual PLCORE_API bool | Unload () override |
Unloads the loadable. | |
virtual PLCORE_API String | GetLoadableTypeName () const override |
Returns the loadable type name. | |
Static Public Attributes | |
static PLCORE_API const String | English |
Localization group.
String PLCore::LocalizationGroup::GetName | ( | ) | const [inline] |
Returns the name of the group.
String PLCore::LocalizationGroup::GetFromLanguage | ( | ) | const [inline] |
Returns the language used as 'from-key'.
void PLCore::LocalizationGroup::SetFromLanguage | ( | const String & | sFrom = English | ) | [inline] |
Sets the language used as 'from-key'.
[in] | sFrom | The language used as 'from-key' |
String PLCore::LocalizationGroup::GetToLanguage | ( | ) | const [inline] |
Returns the language used as 'to-key'.
void PLCore::LocalizationGroup::SetToLanguage | ( | const String & | sTo = English | ) | [inline] |
Sets the language used as 'to-key'.
[in] | sTo | The language used as 'to-key' |
uint32 PLCore::LocalizationGroup::GetNumOfTexts | ( | ) | const [inline] |
Returns the number of texts.
LocalizationText * PLCore::LocalizationGroup::GetText | ( | uint32 | nIndex | ) | const [inline] |
Returns a text by index.
[in] | nIndex | Index of the text |
LocalizationText * PLCore::LocalizationGroup::GetText | ( | const String & | sName | ) | const [inline] |
Returns a text by name.
[in] | sName | Name of the text |
PLCORE_API LocalizationText* PLCore::LocalizationGroup::AddText | ( | const String & | sName, |
const String & | sTranslation | ||
) |
Adds a new text.
[in] | sName | Name of the new text |
[in] | sTranslation | The translation of the text |
PLCORE_API bool PLCore::LocalizationGroup::RemoveText | ( | uint32 | nIndex | ) |
Removes a text by index.
[in] | nIndex | Index of the text |
PLCORE_API bool PLCore::LocalizationGroup::RemoveText | ( | const String & | sName | ) |
Removes a text by name.
[in] | sName | Name of the text |
PLCORE_API void PLCore::LocalizationGroup::RemoveAllTexts | ( | ) |
Removes all texts.
virtual PLCORE_API bool PLCore::LocalizationGroup::Unload | ( | ) | [override, virtual] |
Unloads the loadable.
Reimplemented from PLCore::Loadable.
virtual PLCORE_API String PLCore::LocalizationGroup::GetLoadableTypeName | ( | ) | const [override, virtual] |
PLCORE_API const String PLCore::LocalizationGroup::English [static] |
"English" (default)
|