ICU 59.1  59.1
udateintervalformat.h
Go to the documentation of this file.
1 // © 2016 and later: Unicode, Inc. and others.
2 // License & terms of use: http://www.unicode.org/copyright.html
3 /*
4 *****************************************************************************************
5 * Copyright (C) 2010-2012,2015 International Business Machines
6 * Corporation and others. All Rights Reserved.
7 *****************************************************************************************
8 */
9 
10 #ifndef UDATEINTERVALFORMAT_H
11 #define UDATEINTERVALFORMAT_H
12 
13 #include "unicode/utypes.h"
14 
15 #if !UCONFIG_NO_FORMATTING
16 
17 #include "unicode/umisc.h"
18 #include "unicode/localpointer.h"
19 
81 struct UDateIntervalFormat;
108 U_STABLE UDateIntervalFormat* U_EXPORT2
109 udtitvfmt_open(const char* locale,
110  const UChar* skeleton,
111  int32_t skeletonLength,
112  const UChar* tzID,
113  int32_t tzIDLength,
114  UErrorCode* status);
115 
122 U_STABLE void U_EXPORT2
124 
125 
126 #if U_SHOW_CPLUSPLUS_API
127 
129 
140 
142 
143 #endif
144 
145 
175 U_STABLE int32_t U_EXPORT2
176 udtitvfmt_format(const UDateIntervalFormat* formatter,
177  UDate fromDate,
178  UDate toDate,
179  UChar* result,
180  int32_t resultCapacity,
181  UFieldPosition* position,
182  UErrorCode* status);
183 
184 #endif /* #if !UCONFIG_NO_FORMATTING */
185 
186 #endif
double UDate
Date and Time data type.
Definition: utypes.h:203
C API:misc definitions.
int32_t udtitvfmt_format(const UDateIntervalFormat *formatter, UDate fromDate, UDate toDate, UChar *result, int32_t resultCapacity, UFieldPosition *position, UErrorCode *status)
Formats a date/time range using the conventions established for the UDateIntervalFormat object...
#define U_NAMESPACE_BEGIN
This is used to begin a declaration of a public ICU C++ API.
Definition: uversion.h:131
"Smart pointer" class, closes a UDateIntervalFormat via udtitvfmt_close().
#define U_DEFINE_LOCAL_OPEN_POINTER(LocalPointerClassName, Type, closeFunction)
"Smart pointer" definition macro, deletes objects via the closeFunction.
Definition: localpointer.h:496
struct UDateIntervalFormat UDateIntervalFormat
C typedef for struct UDateIntervalFormat.
A struct representing a range of text containing a specific field.
Definition: umisc.h:34
C++ API: "Smart pointers" for use with and in ICU4C C++ code.
uint16_t UChar
The base type for UTF-16 code units and pointers.
Definition: umachine.h:349
#define U_NAMESPACE_END
This is used to end a declaration of a public ICU C++ API.
Definition: uversion.h:132
UErrorCode
Error code to replace exception handling, so that the code is compatible with all C++ compilers...
Definition: utypes.h:396
void udtitvfmt_close(UDateIntervalFormat *formatter)
Close a UDateIntervalFormat object.
UDateIntervalFormat * udtitvfmt_open(const char *locale, const UChar *skeleton, int32_t skeletonLength, const UChar *tzID, int32_t tzIDLength, UErrorCode *status)
Open a new UDateIntervalFormat object using the predefined rules for a given locale plus a specified ...
Basic definitions for ICU, for both C and C++ APIs.
#define U_STABLE
This is used to declare a function as a stable public ICU C API.
Definition: umachine.h:111