ICU-10884 Applied review comments from Andy Heninger.
X-SVN-Rev: 35862
This commit is contained in:
parent
81e264fb42
commit
b2e714c21a
@ -32,11 +32,6 @@
|
||||
#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]))
|
||||
|
||||
@ -78,11 +73,11 @@ public:
|
||||
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;
|
||||
|
@ -49,6 +49,12 @@ typedef enum UDateRelativeDateTimeFormatterStyle {
|
||||
* @draft ICU 54
|
||||
*/
|
||||
UDAT_STYLE_NARROW,
|
||||
|
||||
/**
|
||||
* The number of styles.
|
||||
* @draft ICU 54
|
||||
*/
|
||||
UDAT_STYLE_COUNT,
|
||||
};
|
||||
|
||||
/**
|
||||
@ -360,9 +366,8 @@ public:
|
||||
* 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
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user