14 #ifndef __RELDATEFMT_H
15 #define __RELDATEFMT_H
29 #if !UCONFIG_NO_FORMATTING
80 #ifndef U_HIDE_DEPRECATED_API
86 #endif // U_HIDE_DEPRECATED_API
169 #ifndef U_HIDE_DRAFT_API
175 #endif // U_HIDE_DRAFT_API
177 #ifndef U_HIDE_DEPRECATED_API
183 #endif // U_HIDE_DEPRECATED_API
229 #ifndef U_HIDE_DEPRECATED_API
235 #endif // U_HIDE_DEPRECATED_API
238 #if !UCONFIG_NO_BREAK_ITERATION
243 class RelativeDateTimeCacheData;
244 class SharedNumberFormat;
245 class SharedPluralRules;
246 class SharedBreakIterator;
249 class FormattedRelativeDateTimeData;
251 #ifndef U_HIDE_DRAFT_API
306 FormattedRelativeDateTimeData *fData;
310 explicit FormattedRelativeDateTime(
UErrorCode errorCode)
311 : fData(nullptr), fErrorCode(errorCode) {}
312 friend class RelativeDateTimeFormatter;
479 #ifndef U_HIDE_DRAFT_API
526 #ifndef U_HIDE_DRAFT_API
574 #ifndef U_HIDE_DRAFT_API
625 #ifndef U_HIDE_DRAFT_API
690 const RelativeDateTimeCacheData* fCache;
691 const SharedNumberFormat *fNumberFormat;
692 const SharedPluralRules *fPluralRules;
695 const SharedBreakIterator *fOptBreakIterator;
704 template<
typename F,
typename... Args>
711 #ifndef U_HIDE_DRAFT_API // for FormattedRelativeDateTime
712 template<
typename F,
typename... Args>
717 #endif // U_HIDE_DRAFT_API
723 FormattedRelativeDateTimeData& output,
725 void formatAbsoluteImpl(
728 FormattedRelativeDateTimeData& output,
730 void formatNumericImpl(
733 FormattedRelativeDateTimeData& output,
735 void formatRelativeImpl(
738 FormattedRelativeDateTimeData& output,
#define U_OVERRIDE
Defined to the C++11 "override" keyword if available.
One more than the highest normal UDateAbsoluteUnit value.
URelativeDateTimeUnit
Represents the unit for formatting a relative date.
UDisplayContext
Display context settings.
C API: Display context types (enum values)
#define U_I18N_API
Set to export library symbols from inside the i18n library, and to import them from outside...
#define U_NAMESPACE_BEGIN
This is used to begin a declaration of a public ICU C++ API.
C API: URelativeDateTimeFormatter, relative date formatting of unit + numeric offset.
The BreakIterator class implements methods for finding the location of boundaries in text...
UDateRelativeDateTimeFormatterStyle
The formatting style.
UDateDirection
Represents a direction for an absolute unit e.g "Next Tuesday" or "Last Tuesday". ...
Plain, which means the absence of a qualifier.
C++ API: Common ICU base class UObject.
Represents a span of a string containing a given field.
#define U_NAMESPACE_END
This is used to end a declaration of a public ICU C++ API.
UErrorCode
Error code to replace exception handling, so that the code is compatible with all C++ compilers...
One more than the highest normal UDateDirection value.
UDateAbsoluteUnit
Represents an absolute unit.
C++ API: Locale ID object.
Basic definitions for ICU, for both C and C++ APIs.
UnicodeString is a string class that stores Unicode characters directly and provides similar function...
One more than the highest normal UDateRelativeUnit value.
UObject is the common ICU "boilerplate" class.
UMemory is the common ICU base class.
Requested operation can not be completed with ICU in its current state.
UDateRelativeUnit
Represents the unit for formatting a relative date.
int8_t UBool
The ICU boolean type.
Base class for objects to which Unicode characters and strings can be appended.
A Locale object represents a specific geographical, political, or cultural region.