|
ICU 73.2
73.2
|
00001 // © 2016 and later: Unicode, Inc. and others. 00002 // License & terms of use: http://www.unicode.org/copyright.html 00003 /* 00004 ******************************************************************************* 00005 * Copyright (C) 2009-2016, International Business Machines Corporation, * 00006 * Google, and others. All Rights Reserved. * 00007 ******************************************************************************* 00008 */ 00009 00010 #ifndef __TMUNIT_H__ 00011 #define __TMUNIT_H__ 00012 00013 00019 #include "unicode/utypes.h" 00020 00021 #if U_SHOW_CPLUSPLUS_API 00022 00023 #include "unicode/measunit.h" 00024 00025 #if !UCONFIG_NO_FORMATTING 00026 00027 U_NAMESPACE_BEGIN 00028 00035 class U_I18N_API TimeUnit: public MeasureUnit { 00036 public: 00041 enum UTimeUnitFields { 00042 UTIMEUNIT_YEAR, 00043 UTIMEUNIT_MONTH, 00044 UTIMEUNIT_DAY, 00045 UTIMEUNIT_WEEK, 00046 UTIMEUNIT_HOUR, 00047 UTIMEUNIT_MINUTE, 00048 UTIMEUNIT_SECOND, 00049 #ifndef U_HIDE_DEPRECATED_API 00050 00054 UTIMEUNIT_FIELD_COUNT 00055 #endif // U_HIDE_DEPRECATED_API 00056 }; 00057 00068 static TimeUnit* U_EXPORT2 createInstance(UTimeUnitFields timeUnitField, 00069 UErrorCode& status); 00070 00071 00076 virtual TimeUnit* clone() const override; 00077 00082 TimeUnit(const TimeUnit& other); 00083 00088 TimeUnit& operator=(const TimeUnit& other); 00089 00098 virtual UClassID getDynamicClassID() const override; 00099 00106 static UClassID U_EXPORT2 getStaticClassID(); 00107 00108 00114 UTimeUnitFields getTimeUnitField() const; 00115 00120 virtual ~TimeUnit(); 00121 00122 private: 00123 UTimeUnitFields fTimeUnitField; 00124 00129 TimeUnit(UTimeUnitFields timeUnitField); 00130 00131 }; 00132 00133 00134 U_NAMESPACE_END 00135 00136 #endif /* #if !UCONFIG_NO_FORMATTING */ 00137 00138 #endif /* U_SHOW_CPLUSPLUS_API */ 00139 00140 #endif // __TMUNIT_H__ 00141 //eof 00142 //
1.7.6.1