libyui
3.0.10
|
#include <YTransText.h>
Public Member Functions | |
YTransText (const std::string &orig, const std::string &translation) | |
YTransText (const std::string &orig) | |
YTransText (const YTransText &src) | |
YTransText & | operator= (const YTransText &src) |
const std::string & | orig () const |
const std::string & | translation () const |
const std::string & | trans () const |
void | setOrig (const std::string &newOrig) |
void | setTranslation (const std::string &newTrans) |
bool | operator< (const YTransText &other) const |
bool | operator> (const YTransText &other) const |
bool | operator== (const YTransText &other) const |
Helper class for translated strings: Stores a message in the original (untranslated) version along with the translation into the current locale.
Definition at line 36 of file YTransText.h.
YTransText::YTransText | ( | const std::string & | orig, |
const std::string & | translation | ||
) | [inline] |
Constructor with both original and translated message.
Definition at line 43 of file YTransText.h.
YTransText::YTransText | ( | const std::string & | orig | ) | [inline] |
Constructor that automatically translates the original message.
Definition at line 50 of file YTransText.h.
YTransText::YTransText | ( | const YTransText & | src | ) | [inline] |
Copy constructor.
Definition at line 58 of file YTransText.h.
bool YTransText::operator< | ( | const YTransText & | other | ) | const [inline] |
operator< : Compares translations.
Definition at line 105 of file YTransText.h.
YTransText& YTransText::operator= | ( | const YTransText & | src | ) | [inline] |
Assignment operator.
Definition at line 67 of file YTransText.h.
bool YTransText::operator== | ( | const YTransText & | other | ) | const [inline] |
operator== : Compares translations.
Definition at line 117 of file YTransText.h.
bool YTransText::operator> | ( | const YTransText & | other | ) | const [inline] |
operator> : Compares translations.
Definition at line 111 of file YTransText.h.
const std::string& YTransText::orig | ( | ) | const [inline] |
Return the original message.
Definition at line 78 of file YTransText.h.
void YTransText::setOrig | ( | const std::string & | newOrig | ) | [inline] |
Set the original message. Does not touch the translation, so make sure you change both if you want to keep them synchronized!
Definition at line 95 of file YTransText.h.
void YTransText::setTranslation | ( | const std::string & | newTrans | ) | [inline] |
Set the translation.
Definition at line 100 of file YTransText.h.
const std::string& YTransText::trans | ( | ) | const [inline] |
Return the translation. ( alias, just as a shortcut )
Definition at line 89 of file YTransText.h.
const std::string& YTransText::translation | ( | ) | const [inline] |
Return the translation.
Definition at line 83 of file YTransText.h.