|
libzypp 17.38.6
|
Language codes (iso639_2/iso639_1). More...
#include <zypp/LanguageCode.h>

Public Member Functions | |
| LanguageCode () | |
| Default Ctor: noCode. | |
| LanguageCode (IdString str_r) | |
| Ctor from string. | |
| LanguageCode (const std::string &str_r) | |
| Ctor from string. | |
| LanguageCode (const char *str_r) | |
| Ctor from string. | |
| ~LanguageCode () | |
| Dtor. | |
| Public Member Functions inherited from zypp::IdStringType< LanguageCode > | |
| IdString | idStr () const |
| bool | empty () const |
| unsigned | size () const |
| const char * | c_str () const |
| std::string | asString () const |
| IdType | id () const |
| operator bool () const | |
| Evaluate in a boolean context ( !
| |
| operator IdString () const | |
| Explicit conversion to IdString. | |
| operator std::string () const | |
| Explicit conversion to std::string. | |
| int | compare (const LanguageCode &rhs) const |
| int | compare (const IdStringType &rhs) const |
| int | compare (const IdString &rhs) const |
| int | compare (const std::string &rhs) const |
| int | compare (const char *rhs) const |
LanguageCode constants. | |
| static const LanguageCode | noCode |
| Empty code. | |
| static const LanguageCode | enCode |
| Last resort "en". | |
| class | IdStringType< LanguageCode > |
| IdString | _str |
| std::string | code () const |
| Return the language code asString. | |
| std::string | name () const |
| Return the translated language name; if unknown the language code. | |
Additional Inherited Members | |
| Public Types inherited from zypp::IdStringType< LanguageCode > | |
| using | IdType |
| Static Public Member Functions inherited from zypp::IdStringType< LanguageCode > | |
| static int | compare (const LanguageCode &lhs, const LanguageCode &rhs) |
| static int | compare (const LanguageCode &lhs, const IdString &rhs) |
| static int | compare (const LanguageCode &lhs, const std::string &rhs) |
| static int | compare (const LanguageCode &lhs, const char *rhs) |
| static int | compare (const IdString &lhs, const LanguageCode &rhs) |
| static int | compare (const IdString &lhs, const IdString &rhs) |
| static int | compare (const IdString &lhs, const std::string &rhs) |
| static int | compare (const IdString &lhs, const char *rhs) |
| static int | compare (const std::string &lhs, const LanguageCode &rhs) |
| static int | compare (const std::string &lhs, const IdString &rhs) |
| static int | compare (const std::string &lhs, const std::string &rhs) |
| static int | compare (const std::string &lhs, const char *rhs) |
| static int | compare (const char *lhs, const LanguageCode &rhs) |
| static int | compare (const char *lhs, const IdString &rhs) |
| static int | compare (const char *lhs, const std::string &rhs) |
| static int | compare (const char *lhs, const char *rhs) |
| Protected Member Functions inherited from zypp::IdStringType< LanguageCode > | |
| IdStringType ()=default | |
| IdStringType (const IdStringType &)=default | |
| IdStringType (IdStringType &&) noexcept=default | |
| IdStringType & | operator= (const IdStringType &)=default |
| IdStringType & | operator= (IdStringType &&) noexcept=default |
| ~IdStringType ()=default | |
Language codes (iso639_2/iso639_1).
In fact the class will not prevent to use a non iso language code. Just a warning will appear in the log.
Definition at line 30 of file LanguageCode.h.
Default Ctor: noCode.
Definition at line 121 of file LanguageCode.cc.
|
explicit |
Ctor from string.
Definition at line 124 of file LanguageCode.cc.
|
explicit |
Ctor from string.
Definition at line 128 of file LanguageCode.cc.
|
explicit |
Ctor from string.
Definition at line 132 of file LanguageCode.cc.
Dtor.
Definition at line 136 of file LanguageCode.cc.
|
inline |
Return the language code asString.
Definition at line 59 of file LanguageCode.h.
| std::string zypp::LanguageCode::name | ( | ) | const |
Return the translated language name; if unknown the language code.
Definition at line 140 of file LanguageCode.cc.
|
friend |
Definition at line 63 of file LanguageCode.h.
|
static |
Empty code.
Definition at line 52 of file LanguageCode.h.
|
static |
Last resort "en".
Definition at line 54 of file LanguageCode.h.
|
private |
Definition at line 67 of file LanguageCode.h.