Index: source/i18n/unicode/dtfmtsym.h |
diff --git a/source/i18n/unicode/dtfmtsym.h b/source/i18n/unicode/dtfmtsym.h |
index bfdf1148acc8a7965d4a7f67695c218754e41ec8..757347881fde5d4f43d842732bfdc6800e640d36 100644 |
--- a/source/i18n/unicode/dtfmtsym.h |
+++ b/source/i18n/unicode/dtfmtsym.h |
@@ -1,6 +1,8 @@ |
-/* |
+// Copyright (C) 2016 and later: Unicode, Inc. and others. |
+// License & terms of use: http://www.unicode.org/copyright.html |
+/* |
******************************************************************************** |
-* Copyright (C) 1997-2015, International Business Machines |
+* Copyright (C) 1997-2016, International Business Machines |
* Corporation and others. All Rights Reserved. |
******************************************************************************** |
* |
@@ -14,10 +16,10 @@ |
* Changed to match C++ conventions |
******************************************************************************** |
*/ |
- |
+ |
#ifndef DTFMTSYM_H |
#define DTFMTSYM_H |
- |
+ |
#include "unicode/utypes.h" |
#if !UCONFIG_NO_FORMATTING |
@@ -29,7 +31,7 @@ |
#include "unicode/ures.h" |
/** |
- * \file |
+ * \file |
* \brief C++ API: Symbols for formatting dates. |
*/ |
@@ -115,7 +117,7 @@ public: |
* data for the default locale, it will return a last-resort object |
* based on hard-coded strings. |
* |
- * @param type Type of calendar (as returned by Calendar::getType). |
+ * @param type Type of calendar (as returned by Calendar::getType). |
* Will be used to access the correct set of strings. |
* (NULL or empty string defaults to "gregorian".) |
* @param status Status code. Failure |
@@ -130,7 +132,7 @@ public: |
* resources for the given locale, in the default calendar (Gregorian). |
* |
* @param locale Locale to load format data from. |
- * @param type Type of calendar (as returned by Calendar::getType). |
+ * @param type Type of calendar (as returned by Calendar::getType). |
* Will be used to access the correct set of strings. |
* (NULL or empty string defaults to "gregorian".) |
* @param status Status code. Failure |
@@ -270,9 +272,15 @@ public: |
* @stable ICU 3.6 |
*/ |
enum DtContextType { |
- FORMAT, |
- STANDALONE, |
- DT_CONTEXT_COUNT |
+ FORMAT, |
+ STANDALONE, |
+#ifndef U_HIDE_DEPRECATED_API |
+ /** |
+ * One more than the highest normal DtContextType value. |
+ * @deprecated ICU 58 The numeric value may change over time, see ICU ticket #12420. |
+ */ |
+ DT_CONTEXT_COUNT |
+#endif // U_HIDE_DEPRECATED_API |
}; |
/** |
@@ -280,17 +288,21 @@ public: |
* @stable ICU 3.6 |
*/ |
enum DtWidthType { |
- ABBREVIATED, |
- WIDE, |
- NARROW, |
- /** |
- * Short width is currently only supported for weekday names. |
- * @stable ICU 51 |
- */ |
- SHORT, |
- /** |
- */ |
- DT_WIDTH_COUNT = 4 |
+ ABBREVIATED, |
+ WIDE, |
+ NARROW, |
+ /** |
+ * Short width is currently only supported for weekday names. |
+ * @stable ICU 51 |
+ */ |
+ SHORT, |
+#ifndef U_HIDE_DEPRECATED_API |
+ /** |
+ * One more than the highest normal DtWidthType value. |
+ * @deprecated ICU 58 The numeric value may change over time, see ICU ticket #12420. |
+ */ |
+ DT_WIDTH_COUNT = 4 |
+#endif // U_HIDE_DEPRECATED_API |
}; |
/** |
@@ -421,24 +433,22 @@ public: |
* @internal |
*/ |
static const UChar ALTERNATE_TIME_SEPARATOR = 0x002e; // '.' |
-#endif /* U_HIDE_INTERNAL_API */ |
-#ifndef U_HIDE_DRAFT_API |
/** |
* Gets the time separator string. For example: ":". |
* @param result Output param which will receive the time separator string. |
* @return A reference to 'result'. |
- * @draft ICU 55 |
+ * @internal |
*/ |
UnicodeString& getTimeSeparatorString(UnicodeString& result) const; |
/** |
* Sets the time separator string. For example: ":". |
* @param newTimeSeparator the new time separator string. |
- * @draft ICU 55 |
+ * @internal |
*/ |
void setTimeSeparatorString(const UnicodeString& newTimeSeparator); |
-#endif /* U_HIDE_DRAFT_API */ |
+#endif /* U_HIDE_INTERNAL_API */ |
/** |
* Gets cyclic year name strings if the calendar has them, by width and context. |
@@ -852,6 +862,42 @@ private: |
*/ |
UBool fCapitalization[kCapContextUsageTypeCount][2]; |
+ /** |
+ * Abbreviated (== short) day period strings. |
+ */ |
+ UnicodeString *fAbbreviatedDayPeriods; |
+ int32_t fAbbreviatedDayPeriodsCount; |
+ |
+ /** |
+ * Wide day period strings. |
+ */ |
+ UnicodeString *fWideDayPeriods; |
+ int32_t fWideDayPeriodsCount; |
+ |
+ /** |
+ * Narrow day period strings. |
+ */ |
+ UnicodeString *fNarrowDayPeriods; |
+ int32_t fNarrowDayPeriodsCount; |
+ |
+ /** |
+ * Stand-alone abbreviated (== short) day period strings. |
+ */ |
+ UnicodeString *fStandaloneAbbreviatedDayPeriods; |
+ int32_t fStandaloneAbbreviatedDayPeriodsCount; |
+ |
+ /** |
+ * Stand-alone wide day period strings. |
+ */ |
+ UnicodeString *fStandaloneWideDayPeriods; |
+ int32_t fStandaloneWideDayPeriodsCount; |
+ |
+ /** |
+ * Stand-alone narrow day period strings. |
+ */ |
+ UnicodeString *fStandaloneNarrowDayPeriods; |
+ int32_t fStandaloneNarrowDayPeriodsCount; |
+ |
private: |
/** valid/actual locale information |
* these are always ICU locales, so the length should not be a problem |