#include <Locale.h>
Inheritance diagram for Core::Locale:
Public Member Functions | |
virtual String * | className (void) const |
Answer receiver class name. | |
virtual Character * | decimalPoint (void) |
virtual String * | encoding (void) |
Static Public Member Functions | |
static Locale * | current (void) |
Protected Member Functions | |
Locale (locale_t cLocale) | |
Protected Attributes | |
locale_t | locale_def |
Static Protected Attributes | |
static Locale * | _current = nil |
|
Definition at line 35 of file Locale.cc. References locale_def. Referenced by current(). 00036 { 00037 locale_def = cLocale; 00038 }
|
|
Answer receiver class name. Because there isn't any standard way to obtain class name this method comes to place. Every class should rewrite this method but many didn't (yet). Reimplemented from Core::Object. Definition at line 53 of file Locale.cc. 00054 { 00055 return new String("Locale"); 00056 }
|
|
Definition at line 41 of file Locale.cc. References _current, Locale(), and nil. Referenced by Core::EncodedStreamFactory::EncodedStreamFactory(), and Core::Number::fromStringRadix(). 00042 { 00043 if (_current == nil) { 00044 /* In case the requested locale doesn't exist, setlocale 00045 * (and newlocale respectively) returns NULL. 00046 */ 00047 _current = new Locale(newlocale(LC_ALL_MASK, setlocale(LC_ALL, ""), NULL)); 00048 } 00049 return _current; 00050 }
|
|
Definition at line 59 of file Locale.cc. References locale_def, and Core::Character::value(). 00060 { 00061 if (locale_def == NULL) return Character::value('.'); 00062 return Character::value(nl_langinfo_l(DECIMAL_POINT, locale_def)[0]); 00063 }
|
|
Definition at line 65 of file Locale.cc. References locale_def. 00066 { 00067 if (locale_def == NULL) return new String("ISO-8859-1"); 00068 return new String(nl_langinfo_l(CODESET, locale_def)); 00069 }
|
|
Definition at line 33 of file Locale.cc. Referenced by current(). |
|
Definition at line 40 of file Locale.h. Referenced by decimalPoint(), encoding(), and Locale(). |