#include "sharedpluralrules.h"
#include "sharednumberformat.h"
-#define RELDATE_STYLE_FULL 0
-#define RELDATE_STYLE_SHORT 1
-#define RELDATE_STYLE_NARROW 2
-#define RELDATE_STYLE_COUNT 3
-
// Copied from uscript_props.cpp
#define LENGTHOF(array) (int32_t)(sizeof(array)/sizeof((array)[0]))
virtual ~RelativeDateTimeCacheData();
// no numbers: e.g Next Tuesday; Yesterday; etc.
- UnicodeString absoluteUnits[RELDATE_STYLE_COUNT][UDAT_ABSOLUTE_UNIT_COUNT][UDAT_DIRECTION_COUNT];
+ UnicodeString absoluteUnits[UDAT_STYLE_COUNT][UDAT_ABSOLUTE_UNIT_COUNT][UDAT_DIRECTION_COUNT];
// has numbers: e.g Next Tuesday; Yesterday; etc. For second index, 0
// means past e.g 5 days ago; 1 means future e.g in 5 days.
- QuantityFormatter relativeUnits[RELDATE_STYLE_COUNT][UDAT_RELATIVE_UNIT_COUNT][2];
+ QuantityFormatter relativeUnits[UDAT_STYLE_COUNT][UDAT_RELATIVE_UNIT_COUNT][2];
void adoptCombinedDateAndTime(MessageFormat *mfToAdopt) {
delete combinedDateAndTime;
* @draft ICU 54
*/
UDAT_STYLE_NARROW,
+
+ /**
+ * The number of styles.
+ * @draft ICU 54
+ */
+ UDAT_STYLE_COUNT,
};
/**
* contents after calling this constructor. Caller may pass NULL for
* this argument if they want default number format behavior.
* @param style the format style. The UDAT_RELATIVE bit field has no effect.
- * @param capitalizationContext The capitalization context must start with
- * U_DISPCTX_CAPITALIZATION_. Otherwise status is set to
- * U_ILLEGAL_ARGUMENT_ERROR
+ * @param capitalizationContext A value from UDisplayContext that pertains to
+ * capitalization.
* @status Any error is returned here.
* @draft ICU 53
*/