Classes |
| struct | i18n::locale_t |
| | simple struct for managing a locale specification More...
|
| class | i18n::Manager |
Functions |
| | i18n::locale_t::locale_t (void) throw () |
| void | i18n::locale_t::clear (void) throw () |
| const char * | i18n::locale_t::getString (void) const throw () |
| bool | i18n::locale_t::isValid (void) const throw () |
| | is this a valid locale?
|
| const char * | i18n::locale_t::getLanguageCode (OUT char *buffer) const throw () |
| | NOTE: for now we use ISO 639-1 (2-character language codes), but in the future this library could use ISO 639-2 (3-character codes) if they become common enough.
|
| const char * | i18n::locale_t::getCountryCode (OUT char *buffer) const throw () |
| const char * | i18n::locale_t::getEncoding (OUT char *buffer) const throw () |
| virtual const char * | i18n::Manager::getLocale (void) const =0 throw () |
| virtual void | i18n::Manager::parseStrings (IN nstream::Stream *stream)=0 |
| | given a named stream (nstream::Stream), parses all localeInfo blocks relevant to this Manager's locale.
|
| virtual void | i18n::Manager::parseFolder (IN nstream::Folder *folder, IN const SetString *extensions=NULL, IN const char *filter=NULL)=0 |
| | recursively walks all child Entries beneath the specified Folder, and calls parseStrings() on each.
|
| virtual const char * | i18n::Manager::getString (IN const char *id) const =0 throw () |
| | retrieves the specified string.
|
| static smart_ptr< Manager > | i18n::Manager::create (IN const char *locale) |
| void | i18n::getLocaleFromString (IN const char *localeString, OUT locale_t &locale) |
| | given a locale string, of the form "xx_yy.zzzz", returns a locale_t
- xx: 2 character language code (ISO 639-1)
- yy: 2 character country code (ISO 3166)
- zzzz: encoding (arbitrary length, only "UTF-8" is supported right now)
|
| bool | i18n::isValidCountryCode (IN const char *country_code) |
| | is this a valid country code? Based on ISO 3166
|
| bool | i18n::isValidLanguageCode (IN const char *language_code) |
| | is this a valid language code? Only supports ISO 639-1 (2-character codes) for now.
|
| bool | i18n::isValidEncoding (IN const char *encoding) |
| | is this a valid encoding? "valid" means "supported by this library", which for right now is just "UTF-8"
|
| const char * | i18n::getString (IN const Manager *mgr, IN const char *id) |
| | returns the string from the given Manager.
|
| const char * | i18n::getHostLocale (void) |
| | attempt to determine the local host locale. Can return NULL!
|
Variables |
| char | i18n::locale_t::string [eMaxLength+1] |
| const char* i18n::locale_t::getLanguageCode |
( |
OUT char * |
buffer |
) |
const throw () [inline, inherited] |
NOTE: for now we use ISO 639-1 (2-character language codes), but in the future this library could use ISO 639-2 (3-character codes) if they become common enough.
Client code should use the locale_t::eBufferSize constant to construct character buffer arrays, to remain forward compatible.
Definition at line 83 of file i18n.h.