1 /* 2 * Copyright 2003-2010, Haiku, Inc. 3 * Distributed under the terms of the MIT Licence. 4 */ 5 #ifndef _COUNTRY_H_ 6 #define _COUNTRY_H_ 7 8 9 #include <List.h> 10 #include <LocaleStrings.h> 11 #include <String.h> 12 #include <SupportDefs.h> 13 14 15 class BBitmap; 16 class BLanguage; 17 class BMessage; 18 19 namespace icu_44 { 20 class DateFormat; 21 class Locale; 22 } 23 24 25 enum { 26 B_METRIC = 0, 27 B_US 28 }; 29 30 31 class BCountry { 32 public: 33 BCountry(const char* languageCode, 34 const char* countryCode); 35 BCountry(const char* languageAndCountryCode 36 = "en_US"); 37 BCountry(const BCountry& other); 38 BCountry& operator=(const BCountry& other); 39 ~BCountry(); 40 41 status_t GetNativeName(BString& name) const; 42 status_t GetName(BString& name, 43 const BLanguage* displayLanguage = NULL 44 ) const; 45 46 const char* Code() const; 47 status_t GetIcon(BBitmap* result) const; 48 49 const char* GetLocalizedString(uint32 id) const; 50 51 status_t GetAvailableTimeZones( 52 BMessage* timeZones) const; 53 54 int8 Measurement() const; 55 56 class Private; 57 private: 58 friend class Private; 59 60 icu_44::Locale* fICULocale; 61 }; 62 63 64 #endif /* _COUNTRY_H_ */ 65