libyui  3.1.4
 All Classes Files Functions Variables Typedefs Enumerations Friends Pages
YTransText Class Reference

Helper class for translated strings: Stores a message in the original (untranslated) version along with the translation into the current locale. More...

#include <YTransText.h>

Public Member Functions

 YTransText (const std::string &orig, const std::string &translation)
 Constructor with both original and translated message.
 
 YTransText (const std::string &orig)
 Constructor that automatically translates the original message.
 
 YTransText (const YTransText &src)
 Copy constructor.
 
YTransTextoperator= (const YTransText &src)
 Assignment operator.
 
const std::string & orig () const
 Return the original message.
 
const std::string & translation () const
 Return the translation.
 
const std::string & trans () const
 Return the translation. More...
 
void setOrig (const std::string &newOrig)
 Set the original message. More...
 
void setTranslation (const std::string &newTrans)
 Set the translation.
 
bool operator< (const YTransText &other) const
 operator< : Compares translations.
 
bool operator> (const YTransText &other) const
 operator> : Compares translations.
 
bool operator== (const YTransText &other) const
 operator== : Compares translations.
 

Detailed Description

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.

Member Function Documentation

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.

const std::string& YTransText::trans ( ) const
inline

Return the translation.

( alias, just as a shortcut )

Definition at line 89 of file YTransText.h.


The documentation for this class was generated from the following file: