]>
Commit | Line | Data |
---|---|---|
f3c0d7a5 A |
1 | // © 2016 and later: Unicode, Inc. and others. |
2 | // License & terms of use: http://www.unicode.org/copyright.html | |
374ca955 A |
3 | /* |
4 | ********************************************************************** | |
2ca993e8 | 5 | * Copyright (c) 2004-2016, International Business Machines |
374ca955 A |
6 | * Corporation and others. All Rights Reserved. |
7 | ********************************************************************** | |
8 | * Author: Alan Liu | |
9 | * Created: April 26, 2004 | |
10 | * Since: ICU 3.0 | |
11 | ********************************************************************** | |
12 | */ | |
13 | #ifndef __MEASUREUNIT_H__ | |
14 | #define __MEASUREUNIT_H__ | |
15 | ||
16 | #include "unicode/utypes.h" | |
17 | ||
340931cb A |
18 | #if U_SHOW_CPLUSPLUS_API |
19 | ||
374ca955 A |
20 | #if !UCONFIG_NO_FORMATTING |
21 | ||
57a6839d | 22 | #include "unicode/unistr.h" |
374ca955 | 23 | |
73c04bcf A |
24 | /** |
25 | * \file | |
26 | * \brief C++ API: A unit for measuring a quantity. | |
27 | */ | |
28 | ||
374ca955 A |
29 | U_NAMESPACE_BEGIN |
30 | ||
57a6839d A |
31 | class StringEnumeration; |
32 | ||
374ca955 A |
33 | /** |
34 | * A unit such as length, mass, volume, currency, etc. A unit is | |
35 | * coupled with a numeric amount to produce a Measure. | |
36 | * | |
374ca955 | 37 | * @author Alan Liu |
73c04bcf | 38 | * @stable ICU 3.0 |
374ca955 A |
39 | */ |
40 | class U_I18N_API MeasureUnit: public UObject { | |
41 | public: | |
57a6839d A |
42 | |
43 | /** | |
44 | * Default constructor. | |
0f5d89e8 | 45 | * Populates the instance with the base dimensionless unit. |
57a6839d A |
46 | * @stable ICU 3.0 |
47 | */ | |
0f5d89e8 | 48 | MeasureUnit(); |
57a6839d A |
49 | |
50 | /** | |
51 | * Copy constructor. | |
b331163b | 52 | * @stable ICU 3.0 |
57a6839d A |
53 | */ |
54 | MeasureUnit(const MeasureUnit &other); | |
55 | ||
56 | /** | |
57 | * Assignment operator. | |
b331163b | 58 | * @stable ICU 3.0 |
57a6839d A |
59 | */ |
60 | MeasureUnit &operator=(const MeasureUnit &other); | |
61 | ||
374ca955 | 62 | /** |
57a6839d | 63 | * Returns a polymorphic clone of this object. The result will |
374ca955 | 64 | * have the same class as returned by getDynamicClassID(). |
73c04bcf | 65 | * @stable ICU 3.0 |
374ca955 | 66 | */ |
340931cb | 67 | virtual MeasureUnit* clone() const; |
374ca955 A |
68 | |
69 | /** | |
70 | * Destructor | |
73c04bcf | 71 | * @stable ICU 3.0 |
374ca955 A |
72 | */ |
73 | virtual ~MeasureUnit(); | |
57a6839d | 74 | |
374ca955 A |
75 | /** |
76 | * Equality operator. Return true if this object is equal | |
77 | * to the given object. | |
73c04bcf | 78 | * @stable ICU 3.0 |
374ca955 | 79 | */ |
57a6839d A |
80 | virtual UBool operator==(const UObject& other) const; |
81 | ||
57a6839d A |
82 | /** |
83 | * Inequality operator. Return true if this object is not equal | |
84 | * to the given object. | |
b331163b | 85 | * @stable ICU 53 |
57a6839d A |
86 | */ |
87 | UBool operator!=(const UObject& other) const { | |
88 | return !(*this == other); | |
89 | } | |
90 | ||
91 | /** | |
92 | * Get the type. | |
b331163b | 93 | * @stable ICU 53 |
57a6839d A |
94 | */ |
95 | const char *getType() const; | |
96 | ||
97 | /** | |
98 | * Get the sub type. | |
b331163b | 99 | * @stable ICU 53 |
57a6839d A |
100 | */ |
101 | const char *getSubtype() const; | |
102 | ||
103 | /** | |
104 | * getAvailable gets all of the available units. | |
105 | * If there are too many units to fit into destCapacity then the | |
106 | * error code is set to U_BUFFER_OVERFLOW_ERROR. | |
107 | * | |
108 | * @param destArray destination buffer. | |
109 | * @param destCapacity number of MeasureUnit instances available at dest. | |
110 | * @param errorCode ICU error code. | |
111 | * @return number of available units. | |
b331163b | 112 | * @stable ICU 53 |
57a6839d A |
113 | */ |
114 | static int32_t getAvailable( | |
115 | MeasureUnit *destArray, | |
116 | int32_t destCapacity, | |
117 | UErrorCode &errorCode); | |
118 | ||
119 | /** | |
120 | * getAvailable gets all of the available units for a specific type. | |
121 | * If there are too many units to fit into destCapacity then the | |
122 | * error code is set to U_BUFFER_OVERFLOW_ERROR. | |
123 | * | |
124 | * @param type the type | |
125 | * @param destArray destination buffer. | |
126 | * @param destCapacity number of MeasureUnit instances available at dest. | |
127 | * @param errorCode ICU error code. | |
128 | * @return number of available units for type. | |
b331163b | 129 | * @stable ICU 53 |
57a6839d A |
130 | */ |
131 | static int32_t getAvailable( | |
132 | const char *type, | |
133 | MeasureUnit *destArray, | |
134 | int32_t destCapacity, | |
135 | UErrorCode &errorCode); | |
136 | ||
137 | /** | |
138 | * getAvailableTypes gets all of the available types. Caller owns the | |
139 | * returned StringEnumeration and must delete it when finished using it. | |
140 | * | |
141 | * @param errorCode ICU error code. | |
142 | * @return the types. | |
b331163b | 143 | * @stable ICU 53 |
57a6839d A |
144 | */ |
145 | static StringEnumeration* getAvailableTypes(UErrorCode &errorCode); | |
57a6839d A |
146 | |
147 | /** | |
148 | * Return the class ID for this class. This is useful only for comparing to | |
149 | * a return value from getDynamicClassID(). For example: | |
150 | * <pre> | |
151 | * . Base* polymorphic_pointer = createPolymorphicObject(); | |
152 | * . if (polymorphic_pointer->getDynamicClassID() == | |
0f5d89e8 | 153 | * . Derived::getStaticClassID()) ... |
57a6839d A |
154 | * </pre> |
155 | * @return The class ID for all objects of this class. | |
b331163b | 156 | * @stable ICU 53 |
57a6839d A |
157 | */ |
158 | static UClassID U_EXPORT2 getStaticClassID(void); | |
159 | ||
160 | /** | |
161 | * Returns a unique class ID POLYMORPHICALLY. Pure virtual override. This | |
162 | * method is to implement a simple version of RTTI, since not all C++ | |
163 | * compilers support genuine RTTI. Polymorphic operator==() and clone() | |
164 | * methods call this method. | |
165 | * | |
166 | * @return The class ID for this object. All objects of a | |
167 | * given class have the same class ID. Objects of | |
168 | * other classes have different class IDs. | |
b331163b | 169 | * @stable ICU 53 |
57a6839d A |
170 | */ |
171 | virtual UClassID getDynamicClassID(void) const; | |
172 | ||
173 | #ifndef U_HIDE_INTERNAL_API | |
174 | /** | |
175 | * ICU use only. | |
176 | * Returns associated array index for this measure unit. Only valid for | |
177 | * non-currency measure units. | |
178 | * @internal | |
179 | */ | |
180 | int32_t getIndex() const; | |
181 | ||
182 | /** | |
183 | * ICU use only. | |
184 | * Returns maximum value from getIndex plus 1. | |
185 | * @internal | |
186 | */ | |
187 | static int32_t getIndexCount(); | |
b331163b | 188 | |
2ca993e8 A |
189 | /** |
190 | * ICU use only. | |
191 | * @return the unit.getIndex() of the unit which has this unit.getType() and unit.getSubtype(), | |
192 | * or a negative value if there is no such unit | |
193 | * @internal | |
194 | */ | |
195 | static int32_t internalGetIndexForTypeAndSubtype(const char *type, const char *subtype); | |
196 | ||
b331163b A |
197 | /** |
198 | * ICU use only. | |
199 | * @internal | |
200 | */ | |
0f5d89e8 A |
201 | static MeasureUnit resolveUnitPerUnit( |
202 | const MeasureUnit &unit, const MeasureUnit &perUnit, bool* isResolved); | |
57a6839d A |
203 | #endif /* U_HIDE_INTERNAL_API */ |
204 | ||
b331163b A |
205 | // All code between the "Start generated createXXX methods" comment and |
206 | // the "End generated createXXX methods" comment is auto generated code | |
207 | // and must not be edited manually. For instructions on how to correctly | |
208 | // update this code, refer to: | |
209 | // http://site.icu-project.org/design/formatting/measureformat/updating-measure-unit | |
210 | // | |
57a6839d A |
211 | // Start generated createXXX methods |
212 | ||
57a6839d | 213 | /** |
3d1f044b | 214 | * Returns by pointer, unit of acceleration: g-force. |
57a6839d | 215 | * Caller owns returned value and must free it. |
3d1f044b | 216 | * Also see {@link #getGForce()}. |
57a6839d | 217 | * @param status ICU error code. |
b331163b | 218 | * @stable ICU 53 |
57a6839d A |
219 | */ |
220 | static MeasureUnit *createGForce(UErrorCode &status); | |
221 | ||
3d1f044b | 222 | #ifndef U_HIDE_DRAFT_API |
b331163b | 223 | /** |
3d1f044b A |
224 | * Returns by value, unit of acceleration: g-force. |
225 | * Also see {@link #createGForce()}. | |
226 | * @draft ICU 64 | |
227 | */ | |
228 | static MeasureUnit getGForce(); | |
229 | #endif /* U_HIDE_DRAFT_API */ | |
230 | ||
231 | /** | |
232 | * Returns by pointer, unit of acceleration: meter-per-second-squared. | |
b331163b | 233 | * Caller owns returned value and must free it. |
3d1f044b | 234 | * Also see {@link #getMeterPerSecondSquared()}. |
b331163b | 235 | * @param status ICU error code. |
2ca993e8 | 236 | * @stable ICU 54 |
b331163b A |
237 | */ |
238 | static MeasureUnit *createMeterPerSecondSquared(UErrorCode &status); | |
239 | ||
3d1f044b | 240 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 241 | /** |
3d1f044b A |
242 | * Returns by value, unit of acceleration: meter-per-second-squared. |
243 | * Also see {@link #createMeterPerSecondSquared()}. | |
244 | * @draft ICU 64 | |
245 | */ | |
246 | static MeasureUnit getMeterPerSecondSquared(); | |
247 | #endif /* U_HIDE_DRAFT_API */ | |
248 | ||
249 | /** | |
250 | * Returns by pointer, unit of angle: arc-minute. | |
57a6839d | 251 | * Caller owns returned value and must free it. |
3d1f044b | 252 | * Also see {@link #getArcMinute()}. |
57a6839d | 253 | * @param status ICU error code. |
b331163b | 254 | * @stable ICU 53 |
57a6839d A |
255 | */ |
256 | static MeasureUnit *createArcMinute(UErrorCode &status); | |
257 | ||
3d1f044b | 258 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 259 | /** |
3d1f044b A |
260 | * Returns by value, unit of angle: arc-minute. |
261 | * Also see {@link #createArcMinute()}. | |
262 | * @draft ICU 64 | |
263 | */ | |
264 | static MeasureUnit getArcMinute(); | |
265 | #endif /* U_HIDE_DRAFT_API */ | |
266 | ||
267 | /** | |
268 | * Returns by pointer, unit of angle: arc-second. | |
57a6839d | 269 | * Caller owns returned value and must free it. |
3d1f044b | 270 | * Also see {@link #getArcSecond()}. |
57a6839d | 271 | * @param status ICU error code. |
b331163b | 272 | * @stable ICU 53 |
57a6839d A |
273 | */ |
274 | static MeasureUnit *createArcSecond(UErrorCode &status); | |
275 | ||
3d1f044b A |
276 | #ifndef U_HIDE_DRAFT_API |
277 | /** | |
278 | * Returns by value, unit of angle: arc-second. | |
279 | * Also see {@link #createArcSecond()}. | |
280 | * @draft ICU 64 | |
281 | */ | |
282 | static MeasureUnit getArcSecond(); | |
283 | #endif /* U_HIDE_DRAFT_API */ | |
284 | ||
57a6839d | 285 | /** |
3d1f044b | 286 | * Returns by pointer, unit of angle: degree. |
57a6839d | 287 | * Caller owns returned value and must free it. |
3d1f044b | 288 | * Also see {@link #getDegree()}. |
57a6839d | 289 | * @param status ICU error code. |
b331163b | 290 | * @stable ICU 53 |
57a6839d A |
291 | */ |
292 | static MeasureUnit *createDegree(UErrorCode &status); | |
293 | ||
3d1f044b | 294 | #ifndef U_HIDE_DRAFT_API |
b331163b | 295 | /** |
3d1f044b A |
296 | * Returns by value, unit of angle: degree. |
297 | * Also see {@link #createDegree()}. | |
298 | * @draft ICU 64 | |
299 | */ | |
300 | static MeasureUnit getDegree(); | |
301 | #endif /* U_HIDE_DRAFT_API */ | |
302 | ||
303 | /** | |
304 | * Returns by pointer, unit of angle: radian. | |
b331163b | 305 | * Caller owns returned value and must free it. |
3d1f044b | 306 | * Also see {@link #getRadian()}. |
b331163b | 307 | * @param status ICU error code. |
2ca993e8 | 308 | * @stable ICU 54 |
b331163b A |
309 | */ |
310 | static MeasureUnit *createRadian(UErrorCode &status); | |
311 | ||
3d1f044b A |
312 | #ifndef U_HIDE_DRAFT_API |
313 | /** | |
314 | * Returns by value, unit of angle: radian. | |
315 | * Also see {@link #createRadian()}. | |
316 | * @draft ICU 64 | |
317 | */ | |
318 | static MeasureUnit getRadian(); | |
319 | #endif /* U_HIDE_DRAFT_API */ | |
320 | ||
2ca993e8 | 321 | /** |
3d1f044b | 322 | * Returns by pointer, unit of angle: revolution. |
2ca993e8 | 323 | * Caller owns returned value and must free it. |
3d1f044b | 324 | * Also see {@link #getRevolutionAngle()}. |
2ca993e8 | 325 | * @param status ICU error code. |
f3c0d7a5 | 326 | * @stable ICU 56 |
2ca993e8 A |
327 | */ |
328 | static MeasureUnit *createRevolutionAngle(UErrorCode &status); | |
2ca993e8 | 329 | |
3d1f044b A |
330 | #ifndef U_HIDE_DRAFT_API |
331 | /** | |
332 | * Returns by value, unit of angle: revolution. | |
333 | * Also see {@link #createRevolutionAngle()}. | |
334 | * @draft ICU 64 | |
335 | */ | |
336 | static MeasureUnit getRevolutionAngle(); | |
337 | #endif /* U_HIDE_DRAFT_API */ | |
338 | ||
57a6839d | 339 | /** |
3d1f044b | 340 | * Returns by pointer, unit of area: acre. |
57a6839d | 341 | * Caller owns returned value and must free it. |
3d1f044b | 342 | * Also see {@link #getAcre()}. |
57a6839d | 343 | * @param status ICU error code. |
b331163b | 344 | * @stable ICU 53 |
57a6839d A |
345 | */ |
346 | static MeasureUnit *createAcre(UErrorCode &status); | |
347 | ||
3d1f044b A |
348 | #ifndef U_HIDE_DRAFT_API |
349 | /** | |
350 | * Returns by value, unit of area: acre. | |
351 | * Also see {@link #createAcre()}. | |
352 | * @draft ICU 64 | |
353 | */ | |
354 | static MeasureUnit getAcre(); | |
355 | #endif /* U_HIDE_DRAFT_API */ | |
356 | ||
357 | #ifndef U_HIDE_DRAFT_API | |
358 | /** | |
359 | * Returns by pointer, unit of area: dunam. | |
360 | * Caller owns returned value and must free it. | |
361 | * Also see {@link #getDunam()}. | |
362 | * @param status ICU error code. | |
363 | * @draft ICU 64 | |
364 | */ | |
365 | static MeasureUnit *createDunam(UErrorCode &status); | |
366 | ||
367 | /** | |
368 | * Returns by value, unit of area: dunam. | |
369 | * Also see {@link #createDunam()}. | |
370 | * @draft ICU 64 | |
371 | */ | |
372 | static MeasureUnit getDunam(); | |
373 | #endif /* U_HIDE_DRAFT_API */ | |
374 | ||
57a6839d | 375 | /** |
3d1f044b | 376 | * Returns by pointer, unit of area: hectare. |
57a6839d | 377 | * Caller owns returned value and must free it. |
3d1f044b | 378 | * Also see {@link #getHectare()}. |
57a6839d | 379 | * @param status ICU error code. |
b331163b | 380 | * @stable ICU 53 |
57a6839d A |
381 | */ |
382 | static MeasureUnit *createHectare(UErrorCode &status); | |
383 | ||
3d1f044b | 384 | #ifndef U_HIDE_DRAFT_API |
b331163b | 385 | /** |
3d1f044b A |
386 | * Returns by value, unit of area: hectare. |
387 | * Also see {@link #createHectare()}. | |
388 | * @draft ICU 64 | |
389 | */ | |
390 | static MeasureUnit getHectare(); | |
391 | #endif /* U_HIDE_DRAFT_API */ | |
392 | ||
393 | /** | |
394 | * Returns by pointer, unit of area: square-centimeter. | |
b331163b | 395 | * Caller owns returned value and must free it. |
3d1f044b | 396 | * Also see {@link #getSquareCentimeter()}. |
b331163b | 397 | * @param status ICU error code. |
2ca993e8 | 398 | * @stable ICU 54 |
b331163b A |
399 | */ |
400 | static MeasureUnit *createSquareCentimeter(UErrorCode &status); | |
401 | ||
3d1f044b A |
402 | #ifndef U_HIDE_DRAFT_API |
403 | /** | |
404 | * Returns by value, unit of area: square-centimeter. | |
405 | * Also see {@link #createSquareCentimeter()}. | |
406 | * @draft ICU 64 | |
407 | */ | |
408 | static MeasureUnit getSquareCentimeter(); | |
409 | #endif /* U_HIDE_DRAFT_API */ | |
410 | ||
57a6839d | 411 | /** |
3d1f044b | 412 | * Returns by pointer, unit of area: square-foot. |
57a6839d | 413 | * Caller owns returned value and must free it. |
3d1f044b | 414 | * Also see {@link #getSquareFoot()}. |
57a6839d | 415 | * @param status ICU error code. |
b331163b | 416 | * @stable ICU 53 |
57a6839d A |
417 | */ |
418 | static MeasureUnit *createSquareFoot(UErrorCode &status); | |
419 | ||
3d1f044b | 420 | #ifndef U_HIDE_DRAFT_API |
b331163b | 421 | /** |
3d1f044b A |
422 | * Returns by value, unit of area: square-foot. |
423 | * Also see {@link #createSquareFoot()}. | |
424 | * @draft ICU 64 | |
425 | */ | |
426 | static MeasureUnit getSquareFoot(); | |
427 | #endif /* U_HIDE_DRAFT_API */ | |
428 | ||
429 | /** | |
430 | * Returns by pointer, unit of area: square-inch. | |
b331163b | 431 | * Caller owns returned value and must free it. |
3d1f044b | 432 | * Also see {@link #getSquareInch()}. |
b331163b | 433 | * @param status ICU error code. |
2ca993e8 | 434 | * @stable ICU 54 |
b331163b A |
435 | */ |
436 | static MeasureUnit *createSquareInch(UErrorCode &status); | |
437 | ||
3d1f044b A |
438 | #ifndef U_HIDE_DRAFT_API |
439 | /** | |
440 | * Returns by value, unit of area: square-inch. | |
441 | * Also see {@link #createSquareInch()}. | |
442 | * @draft ICU 64 | |
443 | */ | |
444 | static MeasureUnit getSquareInch(); | |
445 | #endif /* U_HIDE_DRAFT_API */ | |
446 | ||
57a6839d | 447 | /** |
3d1f044b | 448 | * Returns by pointer, unit of area: square-kilometer. |
57a6839d | 449 | * Caller owns returned value and must free it. |
3d1f044b | 450 | * Also see {@link #getSquareKilometer()}. |
57a6839d | 451 | * @param status ICU error code. |
b331163b | 452 | * @stable ICU 53 |
57a6839d A |
453 | */ |
454 | static MeasureUnit *createSquareKilometer(UErrorCode &status); | |
455 | ||
3d1f044b | 456 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 457 | /** |
3d1f044b A |
458 | * Returns by value, unit of area: square-kilometer. |
459 | * Also see {@link #createSquareKilometer()}. | |
460 | * @draft ICU 64 | |
461 | */ | |
462 | static MeasureUnit getSquareKilometer(); | |
463 | #endif /* U_HIDE_DRAFT_API */ | |
464 | ||
465 | /** | |
466 | * Returns by pointer, unit of area: square-meter. | |
57a6839d | 467 | * Caller owns returned value and must free it. |
3d1f044b | 468 | * Also see {@link #getSquareMeter()}. |
57a6839d | 469 | * @param status ICU error code. |
b331163b | 470 | * @stable ICU 53 |
57a6839d A |
471 | */ |
472 | static MeasureUnit *createSquareMeter(UErrorCode &status); | |
473 | ||
3d1f044b A |
474 | #ifndef U_HIDE_DRAFT_API |
475 | /** | |
476 | * Returns by value, unit of area: square-meter. | |
477 | * Also see {@link #createSquareMeter()}. | |
478 | * @draft ICU 64 | |
479 | */ | |
480 | static MeasureUnit getSquareMeter(); | |
481 | #endif /* U_HIDE_DRAFT_API */ | |
482 | ||
57a6839d | 483 | /** |
3d1f044b | 484 | * Returns by pointer, unit of area: square-mile. |
57a6839d | 485 | * Caller owns returned value and must free it. |
3d1f044b | 486 | * Also see {@link #getSquareMile()}. |
57a6839d | 487 | * @param status ICU error code. |
b331163b | 488 | * @stable ICU 53 |
57a6839d A |
489 | */ |
490 | static MeasureUnit *createSquareMile(UErrorCode &status); | |
491 | ||
3d1f044b | 492 | #ifndef U_HIDE_DRAFT_API |
b331163b | 493 | /** |
3d1f044b A |
494 | * Returns by value, unit of area: square-mile. |
495 | * Also see {@link #createSquareMile()}. | |
496 | * @draft ICU 64 | |
497 | */ | |
498 | static MeasureUnit getSquareMile(); | |
499 | #endif /* U_HIDE_DRAFT_API */ | |
500 | ||
501 | /** | |
502 | * Returns by pointer, unit of area: square-yard. | |
b331163b | 503 | * Caller owns returned value and must free it. |
3d1f044b | 504 | * Also see {@link #getSquareYard()}. |
b331163b | 505 | * @param status ICU error code. |
2ca993e8 | 506 | * @stable ICU 54 |
b331163b A |
507 | */ |
508 | static MeasureUnit *createSquareYard(UErrorCode &status); | |
509 | ||
3d1f044b | 510 | #ifndef U_HIDE_DRAFT_API |
2ca993e8 | 511 | /** |
3d1f044b A |
512 | * Returns by value, unit of area: square-yard. |
513 | * Also see {@link #createSquareYard()}. | |
514 | * @draft ICU 64 | |
515 | */ | |
516 | static MeasureUnit getSquareYard(); | |
517 | #endif /* U_HIDE_DRAFT_API */ | |
518 | ||
519 | /** | |
520 | * Returns by pointer, unit of concentr: karat. | |
2ca993e8 | 521 | * Caller owns returned value and must free it. |
3d1f044b | 522 | * Also see {@link #getKarat()}. |
2ca993e8 A |
523 | * @param status ICU error code. |
524 | * @stable ICU 54 | |
525 | */ | |
526 | static MeasureUnit *createKarat(UErrorCode &status); | |
527 | ||
3d1f044b | 528 | #ifndef U_HIDE_DRAFT_API |
2ca993e8 | 529 | /** |
3d1f044b A |
530 | * Returns by value, unit of concentr: karat. |
531 | * Also see {@link #createKarat()}. | |
532 | * @draft ICU 64 | |
533 | */ | |
534 | static MeasureUnit getKarat(); | |
535 | #endif /* U_HIDE_DRAFT_API */ | |
536 | ||
537 | /** | |
538 | * Returns by pointer, unit of concentr: milligram-per-deciliter. | |
2ca993e8 | 539 | * Caller owns returned value and must free it. |
3d1f044b | 540 | * Also see {@link #getMilligramPerDeciliter()}. |
2ca993e8 | 541 | * @param status ICU error code. |
f3c0d7a5 | 542 | * @stable ICU 57 |
2ca993e8 A |
543 | */ |
544 | static MeasureUnit *createMilligramPerDeciliter(UErrorCode &status); | |
2ca993e8 | 545 | |
3d1f044b A |
546 | #ifndef U_HIDE_DRAFT_API |
547 | /** | |
548 | * Returns by value, unit of concentr: milligram-per-deciliter. | |
549 | * Also see {@link #createMilligramPerDeciliter()}. | |
550 | * @draft ICU 64 | |
551 | */ | |
552 | static MeasureUnit getMilligramPerDeciliter(); | |
553 | #endif /* U_HIDE_DRAFT_API */ | |
554 | ||
2ca993e8 | 555 | /** |
3d1f044b | 556 | * Returns by pointer, unit of concentr: millimole-per-liter. |
2ca993e8 | 557 | * Caller owns returned value and must free it. |
3d1f044b | 558 | * Also see {@link #getMillimolePerLiter()}. |
2ca993e8 | 559 | * @param status ICU error code. |
f3c0d7a5 | 560 | * @stable ICU 57 |
2ca993e8 A |
561 | */ |
562 | static MeasureUnit *createMillimolePerLiter(UErrorCode &status); | |
2ca993e8 | 563 | |
3d1f044b | 564 | #ifndef U_HIDE_DRAFT_API |
2ca993e8 | 565 | /** |
3d1f044b A |
566 | * Returns by value, unit of concentr: millimole-per-liter. |
567 | * Also see {@link #createMillimolePerLiter()}. | |
568 | * @draft ICU 64 | |
569 | */ | |
570 | static MeasureUnit getMillimolePerLiter(); | |
571 | #endif /* U_HIDE_DRAFT_API */ | |
572 | ||
573 | #ifndef U_HIDE_DRAFT_API | |
574 | /** | |
575 | * Returns by pointer, unit of concentr: mole. | |
576 | * Caller owns returned value and must free it. | |
577 | * Also see {@link #getMole()}. | |
578 | * @param status ICU error code. | |
579 | * @draft ICU 64 | |
580 | */ | |
581 | static MeasureUnit *createMole(UErrorCode &status); | |
582 | ||
583 | /** | |
584 | * Returns by value, unit of concentr: mole. | |
585 | * Also see {@link #createMole()}. | |
586 | * @draft ICU 64 | |
587 | */ | |
588 | static MeasureUnit getMole(); | |
589 | #endif /* U_HIDE_DRAFT_API */ | |
590 | ||
591 | /** | |
592 | * Returns by pointer, unit of concentr: part-per-million. | |
2ca993e8 | 593 | * Caller owns returned value and must free it. |
3d1f044b | 594 | * Also see {@link #getPartPerMillion()}. |
2ca993e8 | 595 | * @param status ICU error code. |
f3c0d7a5 | 596 | * @stable ICU 57 |
2ca993e8 A |
597 | */ |
598 | static MeasureUnit *createPartPerMillion(UErrorCode &status); | |
2ca993e8 | 599 | |
3d1f044b A |
600 | #ifndef U_HIDE_DRAFT_API |
601 | /** | |
602 | * Returns by value, unit of concentr: part-per-million. | |
603 | * Also see {@link #createPartPerMillion()}. | |
604 | * @draft ICU 64 | |
605 | */ | |
606 | static MeasureUnit getPartPerMillion(); | |
607 | #endif /* U_HIDE_DRAFT_API */ | |
608 | ||
3d1f044b A |
609 | /** |
610 | * Returns by pointer, unit of concentr: percent. | |
611 | * Caller owns returned value and must free it. | |
612 | * Also see {@link #getPercent()}. | |
613 | * @param status ICU error code. | |
340931cb | 614 | * @stable ICU 63 |
3d1f044b A |
615 | */ |
616 | static MeasureUnit *createPercent(UErrorCode &status); | |
3d1f044b A |
617 | |
618 | #ifndef U_HIDE_DRAFT_API | |
619 | /** | |
620 | * Returns by value, unit of concentr: percent. | |
621 | * Also see {@link #createPercent()}. | |
622 | * @draft ICU 64 | |
623 | */ | |
624 | static MeasureUnit getPercent(); | |
625 | #endif /* U_HIDE_DRAFT_API */ | |
626 | ||
3d1f044b A |
627 | /** |
628 | * Returns by pointer, unit of concentr: permille. | |
629 | * Caller owns returned value and must free it. | |
630 | * Also see {@link #getPermille()}. | |
631 | * @param status ICU error code. | |
340931cb | 632 | * @stable ICU 63 |
3d1f044b A |
633 | */ |
634 | static MeasureUnit *createPermille(UErrorCode &status); | |
3d1f044b A |
635 | |
636 | #ifndef U_HIDE_DRAFT_API | |
637 | /** | |
638 | * Returns by value, unit of concentr: permille. | |
639 | * Also see {@link #createPermille()}. | |
640 | * @draft ICU 64 | |
641 | */ | |
642 | static MeasureUnit getPermille(); | |
643 | #endif /* U_HIDE_DRAFT_API */ | |
644 | ||
645 | #ifndef U_HIDE_DRAFT_API | |
646 | /** | |
647 | * Returns by pointer, unit of concentr: permyriad. | |
648 | * Caller owns returned value and must free it. | |
649 | * Also see {@link #getPermyriad()}. | |
650 | * @param status ICU error code. | |
651 | * @draft ICU 64 | |
652 | */ | |
653 | static MeasureUnit *createPermyriad(UErrorCode &status); | |
654 | ||
655 | /** | |
656 | * Returns by value, unit of concentr: permyriad. | |
657 | * Also see {@link #createPermyriad()}. | |
658 | * @draft ICU 64 | |
659 | */ | |
660 | static MeasureUnit getPermyriad(); | |
661 | #endif /* U_HIDE_DRAFT_API */ | |
662 | ||
2ca993e8 | 663 | /** |
3d1f044b | 664 | * Returns by pointer, unit of consumption: liter-per-100kilometers. |
2ca993e8 | 665 | * Caller owns returned value and must free it. |
3d1f044b | 666 | * Also see {@link #getLiterPer100Kilometers()}. |
2ca993e8 | 667 | * @param status ICU error code. |
f3c0d7a5 | 668 | * @stable ICU 56 |
2ca993e8 A |
669 | */ |
670 | static MeasureUnit *createLiterPer100Kilometers(UErrorCode &status); | |
2ca993e8 | 671 | |
3d1f044b | 672 | #ifndef U_HIDE_DRAFT_API |
b331163b | 673 | /** |
3d1f044b A |
674 | * Returns by value, unit of consumption: liter-per-100kilometers. |
675 | * Also see {@link #createLiterPer100Kilometers()}. | |
676 | * @draft ICU 64 | |
677 | */ | |
678 | static MeasureUnit getLiterPer100Kilometers(); | |
679 | #endif /* U_HIDE_DRAFT_API */ | |
680 | ||
681 | /** | |
682 | * Returns by pointer, unit of consumption: liter-per-kilometer. | |
b331163b | 683 | * Caller owns returned value and must free it. |
3d1f044b | 684 | * Also see {@link #getLiterPerKilometer()}. |
b331163b | 685 | * @param status ICU error code. |
2ca993e8 | 686 | * @stable ICU 54 |
b331163b A |
687 | */ |
688 | static MeasureUnit *createLiterPerKilometer(UErrorCode &status); | |
689 | ||
3d1f044b | 690 | #ifndef U_HIDE_DRAFT_API |
b331163b | 691 | /** |
3d1f044b A |
692 | * Returns by value, unit of consumption: liter-per-kilometer. |
693 | * Also see {@link #createLiterPerKilometer()}. | |
694 | * @draft ICU 64 | |
695 | */ | |
696 | static MeasureUnit getLiterPerKilometer(); | |
697 | #endif /* U_HIDE_DRAFT_API */ | |
698 | ||
699 | /** | |
700 | * Returns by pointer, unit of consumption: mile-per-gallon. | |
b331163b | 701 | * Caller owns returned value and must free it. |
3d1f044b | 702 | * Also see {@link #getMilePerGallon()}. |
b331163b | 703 | * @param status ICU error code. |
2ca993e8 | 704 | * @stable ICU 54 |
b331163b A |
705 | */ |
706 | static MeasureUnit *createMilePerGallon(UErrorCode &status); | |
707 | ||
3d1f044b | 708 | #ifndef U_HIDE_DRAFT_API |
2ca993e8 | 709 | /** |
3d1f044b A |
710 | * Returns by value, unit of consumption: mile-per-gallon. |
711 | * Also see {@link #createMilePerGallon()}. | |
712 | * @draft ICU 64 | |
713 | */ | |
714 | static MeasureUnit getMilePerGallon(); | |
715 | #endif /* U_HIDE_DRAFT_API */ | |
716 | ||
717 | /** | |
718 | * Returns by pointer, unit of consumption: mile-per-gallon-imperial. | |
2ca993e8 | 719 | * Caller owns returned value and must free it. |
3d1f044b | 720 | * Also see {@link #getMilePerGallonImperial()}. |
2ca993e8 | 721 | * @param status ICU error code. |
f3c0d7a5 | 722 | * @stable ICU 57 |
2ca993e8 A |
723 | */ |
724 | static MeasureUnit *createMilePerGallonImperial(UErrorCode &status); | |
f3c0d7a5 | 725 | |
3d1f044b A |
726 | #ifndef U_HIDE_DRAFT_API |
727 | /** | |
728 | * Returns by value, unit of consumption: mile-per-gallon-imperial. | |
729 | * Also see {@link #createMilePerGallonImperial()}. | |
730 | * @draft ICU 64 | |
731 | */ | |
732 | static MeasureUnit getMilePerGallonImperial(); | |
733 | #endif /* U_HIDE_DRAFT_API */ | |
734 | ||
b331163b | 735 | /** |
3d1f044b | 736 | * Returns by pointer, unit of digital: bit. |
b331163b | 737 | * Caller owns returned value and must free it. |
3d1f044b | 738 | * Also see {@link #getBit()}. |
b331163b | 739 | * @param status ICU error code. |
2ca993e8 | 740 | * @stable ICU 54 |
b331163b A |
741 | */ |
742 | static MeasureUnit *createBit(UErrorCode &status); | |
743 | ||
3d1f044b | 744 | #ifndef U_HIDE_DRAFT_API |
b331163b | 745 | /** |
3d1f044b A |
746 | * Returns by value, unit of digital: bit. |
747 | * Also see {@link #createBit()}. | |
748 | * @draft ICU 64 | |
749 | */ | |
750 | static MeasureUnit getBit(); | |
751 | #endif /* U_HIDE_DRAFT_API */ | |
752 | ||
753 | /** | |
754 | * Returns by pointer, unit of digital: byte. | |
b331163b | 755 | * Caller owns returned value and must free it. |
3d1f044b | 756 | * Also see {@link #getByte()}. |
b331163b | 757 | * @param status ICU error code. |
2ca993e8 | 758 | * @stable ICU 54 |
b331163b A |
759 | */ |
760 | static MeasureUnit *createByte(UErrorCode &status); | |
761 | ||
3d1f044b A |
762 | #ifndef U_HIDE_DRAFT_API |
763 | /** | |
764 | * Returns by value, unit of digital: byte. | |
765 | * Also see {@link #createByte()}. | |
766 | * @draft ICU 64 | |
767 | */ | |
768 | static MeasureUnit getByte(); | |
769 | #endif /* U_HIDE_DRAFT_API */ | |
770 | ||
b331163b | 771 | /** |
3d1f044b | 772 | * Returns by pointer, unit of digital: gigabit. |
b331163b | 773 | * Caller owns returned value and must free it. |
3d1f044b | 774 | * Also see {@link #getGigabit()}. |
b331163b | 775 | * @param status ICU error code. |
2ca993e8 | 776 | * @stable ICU 54 |
b331163b A |
777 | */ |
778 | static MeasureUnit *createGigabit(UErrorCode &status); | |
779 | ||
3d1f044b A |
780 | #ifndef U_HIDE_DRAFT_API |
781 | /** | |
782 | * Returns by value, unit of digital: gigabit. | |
783 | * Also see {@link #createGigabit()}. | |
784 | * @draft ICU 64 | |
785 | */ | |
786 | static MeasureUnit getGigabit(); | |
787 | #endif /* U_HIDE_DRAFT_API */ | |
788 | ||
b331163b | 789 | /** |
3d1f044b | 790 | * Returns by pointer, unit of digital: gigabyte. |
b331163b | 791 | * Caller owns returned value and must free it. |
3d1f044b | 792 | * Also see {@link #getGigabyte()}. |
b331163b | 793 | * @param status ICU error code. |
2ca993e8 | 794 | * @stable ICU 54 |
b331163b A |
795 | */ |
796 | static MeasureUnit *createGigabyte(UErrorCode &status); | |
797 | ||
3d1f044b A |
798 | #ifndef U_HIDE_DRAFT_API |
799 | /** | |
800 | * Returns by value, unit of digital: gigabyte. | |
801 | * Also see {@link #createGigabyte()}. | |
802 | * @draft ICU 64 | |
803 | */ | |
804 | static MeasureUnit getGigabyte(); | |
805 | #endif /* U_HIDE_DRAFT_API */ | |
806 | ||
b331163b | 807 | /** |
3d1f044b | 808 | * Returns by pointer, unit of digital: kilobit. |
b331163b | 809 | * Caller owns returned value and must free it. |
3d1f044b | 810 | * Also see {@link #getKilobit()}. |
b331163b | 811 | * @param status ICU error code. |
2ca993e8 | 812 | * @stable ICU 54 |
b331163b A |
813 | */ |
814 | static MeasureUnit *createKilobit(UErrorCode &status); | |
815 | ||
3d1f044b A |
816 | #ifndef U_HIDE_DRAFT_API |
817 | /** | |
818 | * Returns by value, unit of digital: kilobit. | |
819 | * Also see {@link #createKilobit()}. | |
820 | * @draft ICU 64 | |
821 | */ | |
822 | static MeasureUnit getKilobit(); | |
823 | #endif /* U_HIDE_DRAFT_API */ | |
824 | ||
b331163b | 825 | /** |
3d1f044b | 826 | * Returns by pointer, unit of digital: kilobyte. |
b331163b | 827 | * Caller owns returned value and must free it. |
3d1f044b | 828 | * Also see {@link #getKilobyte()}. |
b331163b | 829 | * @param status ICU error code. |
2ca993e8 | 830 | * @stable ICU 54 |
b331163b A |
831 | */ |
832 | static MeasureUnit *createKilobyte(UErrorCode &status); | |
833 | ||
3d1f044b | 834 | #ifndef U_HIDE_DRAFT_API |
b331163b | 835 | /** |
3d1f044b A |
836 | * Returns by value, unit of digital: kilobyte. |
837 | * Also see {@link #createKilobyte()}. | |
838 | * @draft ICU 64 | |
839 | */ | |
840 | static MeasureUnit getKilobyte(); | |
841 | #endif /* U_HIDE_DRAFT_API */ | |
842 | ||
843 | /** | |
844 | * Returns by pointer, unit of digital: megabit. | |
b331163b | 845 | * Caller owns returned value and must free it. |
3d1f044b | 846 | * Also see {@link #getMegabit()}. |
b331163b | 847 | * @param status ICU error code. |
2ca993e8 | 848 | * @stable ICU 54 |
b331163b A |
849 | */ |
850 | static MeasureUnit *createMegabit(UErrorCode &status); | |
851 | ||
3d1f044b | 852 | #ifndef U_HIDE_DRAFT_API |
b331163b | 853 | /** |
3d1f044b A |
854 | * Returns by value, unit of digital: megabit. |
855 | * Also see {@link #createMegabit()}. | |
856 | * @draft ICU 64 | |
857 | */ | |
858 | static MeasureUnit getMegabit(); | |
859 | #endif /* U_HIDE_DRAFT_API */ | |
860 | ||
861 | /** | |
862 | * Returns by pointer, unit of digital: megabyte. | |
b331163b | 863 | * Caller owns returned value and must free it. |
3d1f044b | 864 | * Also see {@link #getMegabyte()}. |
b331163b | 865 | * @param status ICU error code. |
2ca993e8 | 866 | * @stable ICU 54 |
b331163b A |
867 | */ |
868 | static MeasureUnit *createMegabyte(UErrorCode &status); | |
869 | ||
3d1f044b A |
870 | #ifndef U_HIDE_DRAFT_API |
871 | /** | |
872 | * Returns by value, unit of digital: megabyte. | |
873 | * Also see {@link #createMegabyte()}. | |
874 | * @draft ICU 64 | |
875 | */ | |
876 | static MeasureUnit getMegabyte(); | |
877 | #endif /* U_HIDE_DRAFT_API */ | |
878 | ||
b331163b | 879 | /** |
3d1f044b | 880 | * Returns by pointer, unit of digital: petabyte. |
b331163b | 881 | * Caller owns returned value and must free it. |
3d1f044b A |
882 | * Also see {@link #getPetabyte()}. |
883 | * @param status ICU error code. | |
340931cb | 884 | * @stable ICU 63 |
3d1f044b A |
885 | */ |
886 | static MeasureUnit *createPetabyte(UErrorCode &status); | |
3d1f044b A |
887 | |
888 | #ifndef U_HIDE_DRAFT_API | |
889 | /** | |
890 | * Returns by value, unit of digital: petabyte. | |
891 | * Also see {@link #createPetabyte()}. | |
892 | * @draft ICU 64 | |
893 | */ | |
894 | static MeasureUnit getPetabyte(); | |
895 | #endif /* U_HIDE_DRAFT_API */ | |
896 | ||
897 | /** | |
898 | * Returns by pointer, unit of digital: terabit. | |
899 | * Caller owns returned value and must free it. | |
900 | * Also see {@link #getTerabit()}. | |
b331163b | 901 | * @param status ICU error code. |
2ca993e8 | 902 | * @stable ICU 54 |
b331163b A |
903 | */ |
904 | static MeasureUnit *createTerabit(UErrorCode &status); | |
905 | ||
3d1f044b | 906 | #ifndef U_HIDE_DRAFT_API |
b331163b | 907 | /** |
3d1f044b A |
908 | * Returns by value, unit of digital: terabit. |
909 | * Also see {@link #createTerabit()}. | |
910 | * @draft ICU 64 | |
911 | */ | |
912 | static MeasureUnit getTerabit(); | |
913 | #endif /* U_HIDE_DRAFT_API */ | |
914 | ||
915 | /** | |
916 | * Returns by pointer, unit of digital: terabyte. | |
b331163b | 917 | * Caller owns returned value and must free it. |
3d1f044b | 918 | * Also see {@link #getTerabyte()}. |
b331163b | 919 | * @param status ICU error code. |
2ca993e8 | 920 | * @stable ICU 54 |
b331163b A |
921 | */ |
922 | static MeasureUnit *createTerabyte(UErrorCode &status); | |
923 | ||
3d1f044b A |
924 | #ifndef U_HIDE_DRAFT_API |
925 | /** | |
926 | * Returns by value, unit of digital: terabyte. | |
927 | * Also see {@link #createTerabyte()}. | |
928 | * @draft ICU 64 | |
929 | */ | |
930 | static MeasureUnit getTerabyte(); | |
931 | #endif /* U_HIDE_DRAFT_API */ | |
932 | ||
2ca993e8 | 933 | /** |
3d1f044b | 934 | * Returns by pointer, unit of duration: century. |
2ca993e8 | 935 | * Caller owns returned value and must free it. |
3d1f044b | 936 | * Also see {@link #getCentury()}. |
2ca993e8 | 937 | * @param status ICU error code. |
f3c0d7a5 | 938 | * @stable ICU 56 |
2ca993e8 A |
939 | */ |
940 | static MeasureUnit *createCentury(UErrorCode &status); | |
2ca993e8 | 941 | |
3d1f044b | 942 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 943 | /** |
3d1f044b A |
944 | * Returns by value, unit of duration: century. |
945 | * Also see {@link #createCentury()}. | |
946 | * @draft ICU 64 | |
947 | */ | |
948 | static MeasureUnit getCentury(); | |
949 | #endif /* U_HIDE_DRAFT_API */ | |
950 | ||
951 | /** | |
952 | * Returns by pointer, unit of duration: day. | |
57a6839d | 953 | * Caller owns returned value and must free it. |
3d1f044b | 954 | * Also see {@link #getDay()}. |
57a6839d | 955 | * @param status ICU error code. |
b331163b | 956 | * @stable ICU 53 |
57a6839d A |
957 | */ |
958 | static MeasureUnit *createDay(UErrorCode &status); | |
959 | ||
3d1f044b | 960 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 961 | /** |
3d1f044b A |
962 | * Returns by value, unit of duration: day. |
963 | * Also see {@link #createDay()}. | |
964 | * @draft ICU 64 | |
965 | */ | |
966 | static MeasureUnit getDay(); | |
967 | #endif /* U_HIDE_DRAFT_API */ | |
968 | ||
969 | #ifndef U_HIDE_DRAFT_API | |
970 | /** | |
971 | * Returns by pointer, unit of duration: day-person. | |
57a6839d | 972 | * Caller owns returned value and must free it. |
3d1f044b A |
973 | * Also see {@link #getDayPerson()}. |
974 | * @param status ICU error code. | |
975 | * @draft ICU 64 | |
976 | */ | |
977 | static MeasureUnit *createDayPerson(UErrorCode &status); | |
3d1f044b | 978 | |
3d1f044b A |
979 | /** |
980 | * Returns by value, unit of duration: day-person. | |
981 | * Also see {@link #createDayPerson()}. | |
982 | * @draft ICU 64 | |
983 | */ | |
984 | static MeasureUnit getDayPerson(); | |
985 | #endif /* U_HIDE_DRAFT_API */ | |
986 | ||
340931cb A |
987 | #ifndef U_HIDE_DRAFT_API |
988 | /** | |
989 | * Returns by pointer, unit of duration: decade. | |
990 | * Caller owns returned value and must free it. | |
991 | * Also see {@link #getDecade()}. | |
992 | * @param status ICU error code. | |
993 | * @draft ICU 65 | |
994 | */ | |
995 | static MeasureUnit *createDecade(UErrorCode &status); | |
996 | ||
997 | /** | |
998 | * Returns by value, unit of duration: decade. | |
999 | * Also see {@link #createDecade()}. | |
1000 | * @draft ICU 65 | |
1001 | */ | |
1002 | static MeasureUnit getDecade(); | |
1003 | #endif /* U_HIDE_DRAFT_API */ | |
1004 | ||
3d1f044b A |
1005 | /** |
1006 | * Returns by pointer, unit of duration: hour. | |
1007 | * Caller owns returned value and must free it. | |
1008 | * Also see {@link #getHour()}. | |
57a6839d | 1009 | * @param status ICU error code. |
b331163b | 1010 | * @stable ICU 53 |
57a6839d A |
1011 | */ |
1012 | static MeasureUnit *createHour(UErrorCode &status); | |
1013 | ||
3d1f044b A |
1014 | #ifndef U_HIDE_DRAFT_API |
1015 | /** | |
1016 | * Returns by value, unit of duration: hour. | |
1017 | * Also see {@link #createHour()}. | |
1018 | * @draft ICU 64 | |
1019 | */ | |
1020 | static MeasureUnit getHour(); | |
1021 | #endif /* U_HIDE_DRAFT_API */ | |
1022 | ||
b331163b | 1023 | /** |
3d1f044b | 1024 | * Returns by pointer, unit of duration: microsecond. |
b331163b | 1025 | * Caller owns returned value and must free it. |
3d1f044b | 1026 | * Also see {@link #getMicrosecond()}. |
b331163b | 1027 | * @param status ICU error code. |
2ca993e8 | 1028 | * @stable ICU 54 |
b331163b A |
1029 | */ |
1030 | static MeasureUnit *createMicrosecond(UErrorCode &status); | |
1031 | ||
3d1f044b A |
1032 | #ifndef U_HIDE_DRAFT_API |
1033 | /** | |
1034 | * Returns by value, unit of duration: microsecond. | |
1035 | * Also see {@link #createMicrosecond()}. | |
1036 | * @draft ICU 64 | |
1037 | */ | |
1038 | static MeasureUnit getMicrosecond(); | |
1039 | #endif /* U_HIDE_DRAFT_API */ | |
1040 | ||
57a6839d | 1041 | /** |
3d1f044b | 1042 | * Returns by pointer, unit of duration: millisecond. |
57a6839d | 1043 | * Caller owns returned value and must free it. |
3d1f044b | 1044 | * Also see {@link #getMillisecond()}. |
57a6839d | 1045 | * @param status ICU error code. |
b331163b | 1046 | * @stable ICU 53 |
57a6839d A |
1047 | */ |
1048 | static MeasureUnit *createMillisecond(UErrorCode &status); | |
1049 | ||
3d1f044b A |
1050 | #ifndef U_HIDE_DRAFT_API |
1051 | /** | |
1052 | * Returns by value, unit of duration: millisecond. | |
1053 | * Also see {@link #createMillisecond()}. | |
1054 | * @draft ICU 64 | |
1055 | */ | |
1056 | static MeasureUnit getMillisecond(); | |
1057 | #endif /* U_HIDE_DRAFT_API */ | |
1058 | ||
57a6839d | 1059 | /** |
3d1f044b | 1060 | * Returns by pointer, unit of duration: minute. |
57a6839d | 1061 | * Caller owns returned value and must free it. |
3d1f044b | 1062 | * Also see {@link #getMinute()}. |
57a6839d | 1063 | * @param status ICU error code. |
b331163b | 1064 | * @stable ICU 53 |
57a6839d A |
1065 | */ |
1066 | static MeasureUnit *createMinute(UErrorCode &status); | |
1067 | ||
3d1f044b A |
1068 | #ifndef U_HIDE_DRAFT_API |
1069 | /** | |
1070 | * Returns by value, unit of duration: minute. | |
1071 | * Also see {@link #createMinute()}. | |
1072 | * @draft ICU 64 | |
1073 | */ | |
1074 | static MeasureUnit getMinute(); | |
1075 | #endif /* U_HIDE_DRAFT_API */ | |
1076 | ||
57a6839d | 1077 | /** |
3d1f044b | 1078 | * Returns by pointer, unit of duration: month. |
57a6839d | 1079 | * Caller owns returned value and must free it. |
3d1f044b | 1080 | * Also see {@link #getMonth()}. |
57a6839d | 1081 | * @param status ICU error code. |
b331163b | 1082 | * @stable ICU 53 |
57a6839d A |
1083 | */ |
1084 | static MeasureUnit *createMonth(UErrorCode &status); | |
1085 | ||
3d1f044b A |
1086 | #ifndef U_HIDE_DRAFT_API |
1087 | /** | |
1088 | * Returns by value, unit of duration: month. | |
1089 | * Also see {@link #createMonth()}. | |
1090 | * @draft ICU 64 | |
1091 | */ | |
1092 | static MeasureUnit getMonth(); | |
1093 | #endif /* U_HIDE_DRAFT_API */ | |
1094 | ||
1095 | #ifndef U_HIDE_DRAFT_API | |
b331163b | 1096 | /** |
3d1f044b | 1097 | * Returns by pointer, unit of duration: month-person. |
b331163b | 1098 | * Caller owns returned value and must free it. |
3d1f044b A |
1099 | * Also see {@link #getMonthPerson()}. |
1100 | * @param status ICU error code. | |
1101 | * @draft ICU 64 | |
1102 | */ | |
1103 | static MeasureUnit *createMonthPerson(UErrorCode &status); | |
3d1f044b | 1104 | |
3d1f044b A |
1105 | /** |
1106 | * Returns by value, unit of duration: month-person. | |
1107 | * Also see {@link #createMonthPerson()}. | |
1108 | * @draft ICU 64 | |
1109 | */ | |
1110 | static MeasureUnit getMonthPerson(); | |
1111 | #endif /* U_HIDE_DRAFT_API */ | |
1112 | ||
1113 | /** | |
1114 | * Returns by pointer, unit of duration: nanosecond. | |
1115 | * Caller owns returned value and must free it. | |
1116 | * Also see {@link #getNanosecond()}. | |
b331163b | 1117 | * @param status ICU error code. |
2ca993e8 | 1118 | * @stable ICU 54 |
b331163b A |
1119 | */ |
1120 | static MeasureUnit *createNanosecond(UErrorCode &status); | |
1121 | ||
3d1f044b | 1122 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 1123 | /** |
3d1f044b A |
1124 | * Returns by value, unit of duration: nanosecond. |
1125 | * Also see {@link #createNanosecond()}. | |
1126 | * @draft ICU 64 | |
1127 | */ | |
1128 | static MeasureUnit getNanosecond(); | |
1129 | #endif /* U_HIDE_DRAFT_API */ | |
1130 | ||
1131 | /** | |
1132 | * Returns by pointer, unit of duration: second. | |
57a6839d | 1133 | * Caller owns returned value and must free it. |
3d1f044b | 1134 | * Also see {@link #getSecond()}. |
57a6839d | 1135 | * @param status ICU error code. |
b331163b | 1136 | * @stable ICU 53 |
57a6839d A |
1137 | */ |
1138 | static MeasureUnit *createSecond(UErrorCode &status); | |
1139 | ||
3d1f044b A |
1140 | #ifndef U_HIDE_DRAFT_API |
1141 | /** | |
1142 | * Returns by value, unit of duration: second. | |
1143 | * Also see {@link #createSecond()}. | |
1144 | * @draft ICU 64 | |
1145 | */ | |
1146 | static MeasureUnit getSecond(); | |
1147 | #endif /* U_HIDE_DRAFT_API */ | |
1148 | ||
57a6839d | 1149 | /** |
3d1f044b | 1150 | * Returns by pointer, unit of duration: week. |
57a6839d | 1151 | * Caller owns returned value and must free it. |
3d1f044b | 1152 | * Also see {@link #getWeek()}. |
57a6839d | 1153 | * @param status ICU error code. |
b331163b | 1154 | * @stable ICU 53 |
57a6839d A |
1155 | */ |
1156 | static MeasureUnit *createWeek(UErrorCode &status); | |
1157 | ||
3d1f044b A |
1158 | #ifndef U_HIDE_DRAFT_API |
1159 | /** | |
1160 | * Returns by value, unit of duration: week. | |
1161 | * Also see {@link #createWeek()}. | |
1162 | * @draft ICU 64 | |
1163 | */ | |
1164 | static MeasureUnit getWeek(); | |
1165 | #endif /* U_HIDE_DRAFT_API */ | |
1166 | ||
1167 | #ifndef U_HIDE_DRAFT_API | |
57a6839d | 1168 | /** |
3d1f044b | 1169 | * Returns by pointer, unit of duration: week-person. |
57a6839d | 1170 | * Caller owns returned value and must free it. |
3d1f044b A |
1171 | * Also see {@link #getWeekPerson()}. |
1172 | * @param status ICU error code. | |
1173 | * @draft ICU 64 | |
1174 | */ | |
1175 | static MeasureUnit *createWeekPerson(UErrorCode &status); | |
3d1f044b | 1176 | |
3d1f044b A |
1177 | /** |
1178 | * Returns by value, unit of duration: week-person. | |
1179 | * Also see {@link #createWeekPerson()}. | |
1180 | * @draft ICU 64 | |
1181 | */ | |
1182 | static MeasureUnit getWeekPerson(); | |
1183 | #endif /* U_HIDE_DRAFT_API */ | |
1184 | ||
1185 | /** | |
1186 | * Returns by pointer, unit of duration: year. | |
1187 | * Caller owns returned value and must free it. | |
1188 | * Also see {@link #getYear()}. | |
57a6839d | 1189 | * @param status ICU error code. |
b331163b | 1190 | * @stable ICU 53 |
57a6839d A |
1191 | */ |
1192 | static MeasureUnit *createYear(UErrorCode &status); | |
1193 | ||
3d1f044b A |
1194 | #ifndef U_HIDE_DRAFT_API |
1195 | /** | |
1196 | * Returns by value, unit of duration: year. | |
1197 | * Also see {@link #createYear()}. | |
1198 | * @draft ICU 64 | |
1199 | */ | |
1200 | static MeasureUnit getYear(); | |
1201 | #endif /* U_HIDE_DRAFT_API */ | |
1202 | ||
1203 | #ifndef U_HIDE_DRAFT_API | |
57a6839d | 1204 | /** |
3d1f044b | 1205 | * Returns by pointer, unit of duration: year-person. |
57a6839d | 1206 | * Caller owns returned value and must free it. |
3d1f044b A |
1207 | * Also see {@link #getYearPerson()}. |
1208 | * @param status ICU error code. | |
1209 | * @draft ICU 64 | |
1210 | */ | |
1211 | static MeasureUnit *createYearPerson(UErrorCode &status); | |
3d1f044b | 1212 | |
3d1f044b A |
1213 | /** |
1214 | * Returns by value, unit of duration: year-person. | |
1215 | * Also see {@link #createYearPerson()}. | |
1216 | * @draft ICU 64 | |
1217 | */ | |
1218 | static MeasureUnit getYearPerson(); | |
1219 | #endif /* U_HIDE_DRAFT_API */ | |
1220 | ||
1221 | /** | |
1222 | * Returns by pointer, unit of electric: ampere. | |
1223 | * Caller owns returned value and must free it. | |
1224 | * Also see {@link #getAmpere()}. | |
57a6839d | 1225 | * @param status ICU error code. |
2ca993e8 | 1226 | * @stable ICU 54 |
57a6839d | 1227 | */ |
b331163b | 1228 | static MeasureUnit *createAmpere(UErrorCode &status); |
57a6839d | 1229 | |
3d1f044b A |
1230 | #ifndef U_HIDE_DRAFT_API |
1231 | /** | |
1232 | * Returns by value, unit of electric: ampere. | |
1233 | * Also see {@link #createAmpere()}. | |
1234 | * @draft ICU 64 | |
1235 | */ | |
1236 | static MeasureUnit getAmpere(); | |
1237 | #endif /* U_HIDE_DRAFT_API */ | |
1238 | ||
57a6839d | 1239 | /** |
3d1f044b | 1240 | * Returns by pointer, unit of electric: milliampere. |
57a6839d | 1241 | * Caller owns returned value and must free it. |
3d1f044b | 1242 | * Also see {@link #getMilliampere()}. |
57a6839d | 1243 | * @param status ICU error code. |
2ca993e8 | 1244 | * @stable ICU 54 |
57a6839d | 1245 | */ |
b331163b | 1246 | static MeasureUnit *createMilliampere(UErrorCode &status); |
57a6839d | 1247 | |
3d1f044b A |
1248 | #ifndef U_HIDE_DRAFT_API |
1249 | /** | |
1250 | * Returns by value, unit of electric: milliampere. | |
1251 | * Also see {@link #createMilliampere()}. | |
1252 | * @draft ICU 64 | |
1253 | */ | |
1254 | static MeasureUnit getMilliampere(); | |
1255 | #endif /* U_HIDE_DRAFT_API */ | |
1256 | ||
57a6839d | 1257 | /** |
3d1f044b | 1258 | * Returns by pointer, unit of electric: ohm. |
57a6839d | 1259 | * Caller owns returned value and must free it. |
3d1f044b | 1260 | * Also see {@link #getOhm()}. |
57a6839d | 1261 | * @param status ICU error code. |
2ca993e8 | 1262 | * @stable ICU 54 |
57a6839d | 1263 | */ |
b331163b | 1264 | static MeasureUnit *createOhm(UErrorCode &status); |
57a6839d | 1265 | |
3d1f044b A |
1266 | #ifndef U_HIDE_DRAFT_API |
1267 | /** | |
1268 | * Returns by value, unit of electric: ohm. | |
1269 | * Also see {@link #createOhm()}. | |
1270 | * @draft ICU 64 | |
1271 | */ | |
1272 | static MeasureUnit getOhm(); | |
1273 | #endif /* U_HIDE_DRAFT_API */ | |
1274 | ||
57a6839d | 1275 | /** |
3d1f044b | 1276 | * Returns by pointer, unit of electric: volt. |
57a6839d | 1277 | * Caller owns returned value and must free it. |
3d1f044b | 1278 | * Also see {@link #getVolt()}. |
57a6839d | 1279 | * @param status ICU error code. |
2ca993e8 | 1280 | * @stable ICU 54 |
57a6839d | 1281 | */ |
b331163b | 1282 | static MeasureUnit *createVolt(UErrorCode &status); |
57a6839d | 1283 | |
3d1f044b A |
1284 | #ifndef U_HIDE_DRAFT_API |
1285 | /** | |
1286 | * Returns by value, unit of electric: volt. | |
1287 | * Also see {@link #createVolt()}. | |
1288 | * @draft ICU 64 | |
1289 | */ | |
1290 | static MeasureUnit getVolt(); | |
1291 | #endif /* U_HIDE_DRAFT_API */ | |
1292 | ||
1293 | #ifndef U_HIDE_DRAFT_API | |
57a6839d | 1294 | /** |
3d1f044b | 1295 | * Returns by pointer, unit of energy: british-thermal-unit. |
57a6839d | 1296 | * Caller owns returned value and must free it. |
3d1f044b A |
1297 | * Also see {@link #getBritishThermalUnit()}. |
1298 | * @param status ICU error code. | |
1299 | * @draft ICU 64 | |
1300 | */ | |
1301 | static MeasureUnit *createBritishThermalUnit(UErrorCode &status); | |
1302 | ||
1303 | /** | |
1304 | * Returns by value, unit of energy: british-thermal-unit. | |
1305 | * Also see {@link #createBritishThermalUnit()}. | |
1306 | * @draft ICU 64 | |
1307 | */ | |
1308 | static MeasureUnit getBritishThermalUnit(); | |
1309 | #endif /* U_HIDE_DRAFT_API */ | |
1310 | ||
1311 | /** | |
1312 | * Returns by pointer, unit of energy: calorie. | |
1313 | * Caller owns returned value and must free it. | |
1314 | * Also see {@link #getCalorie()}. | |
57a6839d | 1315 | * @param status ICU error code. |
2ca993e8 | 1316 | * @stable ICU 54 |
57a6839d | 1317 | */ |
b331163b | 1318 | static MeasureUnit *createCalorie(UErrorCode &status); |
57a6839d | 1319 | |
3d1f044b A |
1320 | #ifndef U_HIDE_DRAFT_API |
1321 | /** | |
1322 | * Returns by value, unit of energy: calorie. | |
1323 | * Also see {@link #createCalorie()}. | |
1324 | * @draft ICU 64 | |
1325 | */ | |
1326 | static MeasureUnit getCalorie(); | |
1327 | #endif /* U_HIDE_DRAFT_API */ | |
1328 | ||
1329 | #ifndef U_HIDE_DRAFT_API | |
57a6839d | 1330 | /** |
3d1f044b | 1331 | * Returns by pointer, unit of energy: electronvolt. |
57a6839d | 1332 | * Caller owns returned value and must free it. |
3d1f044b A |
1333 | * Also see {@link #getElectronvolt()}. |
1334 | * @param status ICU error code. | |
1335 | * @draft ICU 64 | |
1336 | */ | |
1337 | static MeasureUnit *createElectronvolt(UErrorCode &status); | |
1338 | ||
1339 | /** | |
1340 | * Returns by value, unit of energy: electronvolt. | |
1341 | * Also see {@link #createElectronvolt()}. | |
1342 | * @draft ICU 64 | |
1343 | */ | |
1344 | static MeasureUnit getElectronvolt(); | |
1345 | #endif /* U_HIDE_DRAFT_API */ | |
1346 | ||
1347 | /** | |
1348 | * Returns by pointer, unit of energy: foodcalorie. | |
1349 | * Caller owns returned value and must free it. | |
1350 | * Also see {@link #getFoodcalorie()}. | |
57a6839d | 1351 | * @param status ICU error code. |
2ca993e8 | 1352 | * @stable ICU 54 |
57a6839d | 1353 | */ |
b331163b | 1354 | static MeasureUnit *createFoodcalorie(UErrorCode &status); |
57a6839d | 1355 | |
3d1f044b A |
1356 | #ifndef U_HIDE_DRAFT_API |
1357 | /** | |
1358 | * Returns by value, unit of energy: foodcalorie. | |
1359 | * Also see {@link #createFoodcalorie()}. | |
1360 | * @draft ICU 64 | |
1361 | */ | |
1362 | static MeasureUnit getFoodcalorie(); | |
1363 | #endif /* U_HIDE_DRAFT_API */ | |
1364 | ||
57a6839d | 1365 | /** |
3d1f044b | 1366 | * Returns by pointer, unit of energy: joule. |
57a6839d | 1367 | * Caller owns returned value and must free it. |
3d1f044b | 1368 | * Also see {@link #getJoule()}. |
57a6839d | 1369 | * @param status ICU error code. |
2ca993e8 | 1370 | * @stable ICU 54 |
57a6839d | 1371 | */ |
b331163b | 1372 | static MeasureUnit *createJoule(UErrorCode &status); |
57a6839d | 1373 | |
3d1f044b A |
1374 | #ifndef U_HIDE_DRAFT_API |
1375 | /** | |
1376 | * Returns by value, unit of energy: joule. | |
1377 | * Also see {@link #createJoule()}. | |
1378 | * @draft ICU 64 | |
1379 | */ | |
1380 | static MeasureUnit getJoule(); | |
1381 | #endif /* U_HIDE_DRAFT_API */ | |
1382 | ||
57a6839d | 1383 | /** |
3d1f044b | 1384 | * Returns by pointer, unit of energy: kilocalorie. |
57a6839d | 1385 | * Caller owns returned value and must free it. |
3d1f044b | 1386 | * Also see {@link #getKilocalorie()}. |
57a6839d | 1387 | * @param status ICU error code. |
2ca993e8 | 1388 | * @stable ICU 54 |
57a6839d | 1389 | */ |
b331163b | 1390 | static MeasureUnit *createKilocalorie(UErrorCode &status); |
57a6839d | 1391 | |
3d1f044b | 1392 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 1393 | /** |
3d1f044b A |
1394 | * Returns by value, unit of energy: kilocalorie. |
1395 | * Also see {@link #createKilocalorie()}. | |
1396 | * @draft ICU 64 | |
1397 | */ | |
1398 | static MeasureUnit getKilocalorie(); | |
1399 | #endif /* U_HIDE_DRAFT_API */ | |
1400 | ||
1401 | /** | |
1402 | * Returns by pointer, unit of energy: kilojoule. | |
57a6839d | 1403 | * Caller owns returned value and must free it. |
3d1f044b | 1404 | * Also see {@link #getKilojoule()}. |
57a6839d | 1405 | * @param status ICU error code. |
2ca993e8 | 1406 | * @stable ICU 54 |
57a6839d | 1407 | */ |
b331163b | 1408 | static MeasureUnit *createKilojoule(UErrorCode &status); |
57a6839d | 1409 | |
3d1f044b | 1410 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 1411 | /** |
3d1f044b A |
1412 | * Returns by value, unit of energy: kilojoule. |
1413 | * Also see {@link #createKilojoule()}. | |
1414 | * @draft ICU 64 | |
1415 | */ | |
1416 | static MeasureUnit getKilojoule(); | |
1417 | #endif /* U_HIDE_DRAFT_API */ | |
1418 | ||
1419 | /** | |
1420 | * Returns by pointer, unit of energy: kilowatt-hour. | |
57a6839d | 1421 | * Caller owns returned value and must free it. |
3d1f044b | 1422 | * Also see {@link #getKilowattHour()}. |
57a6839d | 1423 | * @param status ICU error code. |
2ca993e8 | 1424 | * @stable ICU 54 |
57a6839d | 1425 | */ |
b331163b | 1426 | static MeasureUnit *createKilowattHour(UErrorCode &status); |
57a6839d | 1427 | |
3d1f044b A |
1428 | #ifndef U_HIDE_DRAFT_API |
1429 | /** | |
1430 | * Returns by value, unit of energy: kilowatt-hour. | |
1431 | * Also see {@link #createKilowattHour()}. | |
1432 | * @draft ICU 64 | |
1433 | */ | |
1434 | static MeasureUnit getKilowattHour(); | |
1435 | #endif /* U_HIDE_DRAFT_API */ | |
1436 | ||
340931cb A |
1437 | #ifndef U_HIDE_DRAFT_API |
1438 | /** | |
1439 | * Returns by pointer, unit of energy: therm-us. | |
1440 | * Caller owns returned value and must free it. | |
1441 | * Also see {@link #getThermUs()}. | |
1442 | * @param status ICU error code. | |
1443 | * @draft ICU 65 | |
1444 | */ | |
1445 | static MeasureUnit *createThermUs(UErrorCode &status); | |
1446 | ||
1447 | /** | |
1448 | * Returns by value, unit of energy: therm-us. | |
1449 | * Also see {@link #createThermUs()}. | |
1450 | * @draft ICU 65 | |
1451 | */ | |
1452 | static MeasureUnit getThermUs(); | |
1453 | #endif /* U_HIDE_DRAFT_API */ | |
1454 | ||
3d1f044b A |
1455 | #ifndef U_HIDE_DRAFT_API |
1456 | /** | |
1457 | * Returns by pointer, unit of force: newton. | |
1458 | * Caller owns returned value and must free it. | |
1459 | * Also see {@link #getNewton()}. | |
1460 | * @param status ICU error code. | |
1461 | * @draft ICU 64 | |
1462 | */ | |
1463 | static MeasureUnit *createNewton(UErrorCode &status); | |
1464 | ||
1465 | /** | |
1466 | * Returns by value, unit of force: newton. | |
1467 | * Also see {@link #createNewton()}. | |
1468 | * @draft ICU 64 | |
1469 | */ | |
1470 | static MeasureUnit getNewton(); | |
1471 | #endif /* U_HIDE_DRAFT_API */ | |
1472 | ||
1473 | #ifndef U_HIDE_DRAFT_API | |
1474 | /** | |
1475 | * Returns by pointer, unit of force: pound-force. | |
1476 | * Caller owns returned value and must free it. | |
1477 | * Also see {@link #getPoundForce()}. | |
1478 | * @param status ICU error code. | |
1479 | * @draft ICU 64 | |
1480 | */ | |
1481 | static MeasureUnit *createPoundForce(UErrorCode &status); | |
1482 | ||
1483 | /** | |
1484 | * Returns by value, unit of force: pound-force. | |
1485 | * Also see {@link #createPoundForce()}. | |
1486 | * @draft ICU 64 | |
1487 | */ | |
1488 | static MeasureUnit getPoundForce(); | |
1489 | #endif /* U_HIDE_DRAFT_API */ | |
1490 | ||
57a6839d | 1491 | /** |
3d1f044b | 1492 | * Returns by pointer, unit of frequency: gigahertz. |
57a6839d | 1493 | * Caller owns returned value and must free it. |
3d1f044b | 1494 | * Also see {@link #getGigahertz()}. |
57a6839d | 1495 | * @param status ICU error code. |
2ca993e8 | 1496 | * @stable ICU 54 |
57a6839d | 1497 | */ |
b331163b | 1498 | static MeasureUnit *createGigahertz(UErrorCode &status); |
57a6839d | 1499 | |
3d1f044b | 1500 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 1501 | /** |
3d1f044b A |
1502 | * Returns by value, unit of frequency: gigahertz. |
1503 | * Also see {@link #createGigahertz()}. | |
1504 | * @draft ICU 64 | |
1505 | */ | |
1506 | static MeasureUnit getGigahertz(); | |
1507 | #endif /* U_HIDE_DRAFT_API */ | |
1508 | ||
1509 | /** | |
1510 | * Returns by pointer, unit of frequency: hertz. | |
57a6839d | 1511 | * Caller owns returned value and must free it. |
3d1f044b | 1512 | * Also see {@link #getHertz()}. |
57a6839d | 1513 | * @param status ICU error code. |
2ca993e8 | 1514 | * @stable ICU 54 |
57a6839d | 1515 | */ |
b331163b | 1516 | static MeasureUnit *createHertz(UErrorCode &status); |
57a6839d | 1517 | |
3d1f044b | 1518 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 1519 | /** |
3d1f044b A |
1520 | * Returns by value, unit of frequency: hertz. |
1521 | * Also see {@link #createHertz()}. | |
1522 | * @draft ICU 64 | |
1523 | */ | |
1524 | static MeasureUnit getHertz(); | |
1525 | #endif /* U_HIDE_DRAFT_API */ | |
1526 | ||
1527 | /** | |
1528 | * Returns by pointer, unit of frequency: kilohertz. | |
57a6839d | 1529 | * Caller owns returned value and must free it. |
3d1f044b | 1530 | * Also see {@link #getKilohertz()}. |
57a6839d | 1531 | * @param status ICU error code. |
2ca993e8 | 1532 | * @stable ICU 54 |
57a6839d | 1533 | */ |
b331163b | 1534 | static MeasureUnit *createKilohertz(UErrorCode &status); |
57a6839d | 1535 | |
3d1f044b A |
1536 | #ifndef U_HIDE_DRAFT_API |
1537 | /** | |
1538 | * Returns by value, unit of frequency: kilohertz. | |
1539 | * Also see {@link #createKilohertz()}. | |
1540 | * @draft ICU 64 | |
1541 | */ | |
1542 | static MeasureUnit getKilohertz(); | |
1543 | #endif /* U_HIDE_DRAFT_API */ | |
1544 | ||
57a6839d | 1545 | /** |
3d1f044b | 1546 | * Returns by pointer, unit of frequency: megahertz. |
57a6839d | 1547 | * Caller owns returned value and must free it. |
3d1f044b | 1548 | * Also see {@link #getMegahertz()}. |
57a6839d | 1549 | * @param status ICU error code. |
2ca993e8 | 1550 | * @stable ICU 54 |
57a6839d | 1551 | */ |
b331163b | 1552 | static MeasureUnit *createMegahertz(UErrorCode &status); |
57a6839d | 1553 | |
3d1f044b | 1554 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 1555 | /** |
3d1f044b A |
1556 | * Returns by value, unit of frequency: megahertz. |
1557 | * Also see {@link #createMegahertz()}. | |
1558 | * @draft ICU 64 | |
1559 | */ | |
1560 | static MeasureUnit getMegahertz(); | |
1561 | #endif /* U_HIDE_DRAFT_API */ | |
1562 | ||
340931cb A |
1563 | #ifndef U_HIDE_DRAFT_API |
1564 | /** | |
1565 | * Returns by pointer, unit of graphics: dot-per-centimeter. | |
1566 | * Caller owns returned value and must free it. | |
1567 | * Also see {@link #getDotPerCentimeter()}. | |
1568 | * @param status ICU error code. | |
1569 | * @draft ICU 65 | |
1570 | */ | |
1571 | static MeasureUnit *createDotPerCentimeter(UErrorCode &status); | |
1572 | ||
1573 | /** | |
1574 | * Returns by value, unit of graphics: dot-per-centimeter. | |
1575 | * Also see {@link #createDotPerCentimeter()}. | |
1576 | * @draft ICU 65 | |
1577 | */ | |
1578 | static MeasureUnit getDotPerCentimeter(); | |
1579 | #endif /* U_HIDE_DRAFT_API */ | |
1580 | ||
1581 | #ifndef U_HIDE_DRAFT_API | |
1582 | /** | |
1583 | * Returns by pointer, unit of graphics: dot-per-inch. | |
1584 | * Caller owns returned value and must free it. | |
1585 | * Also see {@link #getDotPerInch()}. | |
1586 | * @param status ICU error code. | |
1587 | * @draft ICU 65 | |
1588 | */ | |
1589 | static MeasureUnit *createDotPerInch(UErrorCode &status); | |
1590 | ||
1591 | /** | |
1592 | * Returns by value, unit of graphics: dot-per-inch. | |
1593 | * Also see {@link #createDotPerInch()}. | |
1594 | * @draft ICU 65 | |
1595 | */ | |
1596 | static MeasureUnit getDotPerInch(); | |
1597 | #endif /* U_HIDE_DRAFT_API */ | |
1598 | ||
1599 | #ifndef U_HIDE_DRAFT_API | |
1600 | /** | |
1601 | * Returns by pointer, unit of graphics: em. | |
1602 | * Caller owns returned value and must free it. | |
1603 | * Also see {@link #getEm()}. | |
1604 | * @param status ICU error code. | |
1605 | * @draft ICU 65 | |
1606 | */ | |
1607 | static MeasureUnit *createEm(UErrorCode &status); | |
1608 | ||
1609 | /** | |
1610 | * Returns by value, unit of graphics: em. | |
1611 | * Also see {@link #createEm()}. | |
1612 | * @draft ICU 65 | |
1613 | */ | |
1614 | static MeasureUnit getEm(); | |
1615 | #endif /* U_HIDE_DRAFT_API */ | |
1616 | ||
1617 | #ifndef U_HIDE_DRAFT_API | |
1618 | /** | |
1619 | * Returns by pointer, unit of graphics: megapixel. | |
1620 | * Caller owns returned value and must free it. | |
1621 | * Also see {@link #getMegapixel()}. | |
1622 | * @param status ICU error code. | |
1623 | * @draft ICU 65 | |
1624 | */ | |
1625 | static MeasureUnit *createMegapixel(UErrorCode &status); | |
1626 | ||
1627 | /** | |
1628 | * Returns by value, unit of graphics: megapixel. | |
1629 | * Also see {@link #createMegapixel()}. | |
1630 | * @draft ICU 65 | |
1631 | */ | |
1632 | static MeasureUnit getMegapixel(); | |
1633 | #endif /* U_HIDE_DRAFT_API */ | |
1634 | ||
1635 | #ifndef U_HIDE_DRAFT_API | |
1636 | /** | |
1637 | * Returns by pointer, unit of graphics: pixel. | |
1638 | * Caller owns returned value and must free it. | |
1639 | * Also see {@link #getPixel()}. | |
1640 | * @param status ICU error code. | |
1641 | * @draft ICU 65 | |
1642 | */ | |
1643 | static MeasureUnit *createPixel(UErrorCode &status); | |
1644 | ||
1645 | /** | |
1646 | * Returns by value, unit of graphics: pixel. | |
1647 | * Also see {@link #createPixel()}. | |
1648 | * @draft ICU 65 | |
1649 | */ | |
1650 | static MeasureUnit getPixel(); | |
1651 | #endif /* U_HIDE_DRAFT_API */ | |
1652 | ||
1653 | #ifndef U_HIDE_DRAFT_API | |
1654 | /** | |
1655 | * Returns by pointer, unit of graphics: pixel-per-centimeter. | |
1656 | * Caller owns returned value and must free it. | |
1657 | * Also see {@link #getPixelPerCentimeter()}. | |
1658 | * @param status ICU error code. | |
1659 | * @draft ICU 65 | |
1660 | */ | |
1661 | static MeasureUnit *createPixelPerCentimeter(UErrorCode &status); | |
1662 | ||
1663 | /** | |
1664 | * Returns by value, unit of graphics: pixel-per-centimeter. | |
1665 | * Also see {@link #createPixelPerCentimeter()}. | |
1666 | * @draft ICU 65 | |
1667 | */ | |
1668 | static MeasureUnit getPixelPerCentimeter(); | |
1669 | #endif /* U_HIDE_DRAFT_API */ | |
1670 | ||
1671 | #ifndef U_HIDE_DRAFT_API | |
1672 | /** | |
1673 | * Returns by pointer, unit of graphics: pixel-per-inch. | |
1674 | * Caller owns returned value and must free it. | |
1675 | * Also see {@link #getPixelPerInch()}. | |
1676 | * @param status ICU error code. | |
1677 | * @draft ICU 65 | |
1678 | */ | |
1679 | static MeasureUnit *createPixelPerInch(UErrorCode &status); | |
1680 | ||
1681 | /** | |
1682 | * Returns by value, unit of graphics: pixel-per-inch. | |
1683 | * Also see {@link #createPixelPerInch()}. | |
1684 | * @draft ICU 65 | |
1685 | */ | |
1686 | static MeasureUnit getPixelPerInch(); | |
1687 | #endif /* U_HIDE_DRAFT_API */ | |
1688 | ||
3d1f044b A |
1689 | /** |
1690 | * Returns by pointer, unit of length: astronomical-unit. | |
57a6839d | 1691 | * Caller owns returned value and must free it. |
3d1f044b | 1692 | * Also see {@link #getAstronomicalUnit()}. |
57a6839d | 1693 | * @param status ICU error code. |
2ca993e8 | 1694 | * @stable ICU 54 |
57a6839d | 1695 | */ |
b331163b | 1696 | static MeasureUnit *createAstronomicalUnit(UErrorCode &status); |
57a6839d | 1697 | |
3d1f044b A |
1698 | #ifndef U_HIDE_DRAFT_API |
1699 | /** | |
1700 | * Returns by value, unit of length: astronomical-unit. | |
1701 | * Also see {@link #createAstronomicalUnit()}. | |
1702 | * @draft ICU 64 | |
1703 | */ | |
1704 | static MeasureUnit getAstronomicalUnit(); | |
1705 | #endif /* U_HIDE_DRAFT_API */ | |
1706 | ||
57a6839d | 1707 | /** |
3d1f044b | 1708 | * Returns by pointer, unit of length: centimeter. |
57a6839d | 1709 | * Caller owns returned value and must free it. |
3d1f044b | 1710 | * Also see {@link #getCentimeter()}. |
57a6839d | 1711 | * @param status ICU error code. |
b331163b | 1712 | * @stable ICU 53 |
57a6839d | 1713 | */ |
b331163b | 1714 | static MeasureUnit *createCentimeter(UErrorCode &status); |
57a6839d | 1715 | |
3d1f044b A |
1716 | #ifndef U_HIDE_DRAFT_API |
1717 | /** | |
1718 | * Returns by value, unit of length: centimeter. | |
1719 | * Also see {@link #createCentimeter()}. | |
1720 | * @draft ICU 64 | |
1721 | */ | |
1722 | static MeasureUnit getCentimeter(); | |
1723 | #endif /* U_HIDE_DRAFT_API */ | |
1724 | ||
57a6839d | 1725 | /** |
3d1f044b | 1726 | * Returns by pointer, unit of length: decimeter. |
57a6839d | 1727 | * Caller owns returned value and must free it. |
3d1f044b | 1728 | * Also see {@link #getDecimeter()}. |
57a6839d | 1729 | * @param status ICU error code. |
2ca993e8 | 1730 | * @stable ICU 54 |
57a6839d | 1731 | */ |
b331163b | 1732 | static MeasureUnit *createDecimeter(UErrorCode &status); |
57a6839d | 1733 | |
3d1f044b A |
1734 | #ifndef U_HIDE_DRAFT_API |
1735 | /** | |
1736 | * Returns by value, unit of length: decimeter. | |
1737 | * Also see {@link #createDecimeter()}. | |
1738 | * @draft ICU 64 | |
1739 | */ | |
1740 | static MeasureUnit getDecimeter(); | |
1741 | #endif /* U_HIDE_DRAFT_API */ | |
1742 | ||
57a6839d | 1743 | /** |
3d1f044b | 1744 | * Returns by pointer, unit of length: fathom. |
57a6839d | 1745 | * Caller owns returned value and must free it. |
3d1f044b | 1746 | * Also see {@link #getFathom()}. |
57a6839d | 1747 | * @param status ICU error code. |
2ca993e8 | 1748 | * @stable ICU 54 |
57a6839d | 1749 | */ |
b331163b | 1750 | static MeasureUnit *createFathom(UErrorCode &status); |
57a6839d | 1751 | |
3d1f044b | 1752 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 1753 | /** |
3d1f044b A |
1754 | * Returns by value, unit of length: fathom. |
1755 | * Also see {@link #createFathom()}. | |
1756 | * @draft ICU 64 | |
1757 | */ | |
1758 | static MeasureUnit getFathom(); | |
1759 | #endif /* U_HIDE_DRAFT_API */ | |
1760 | ||
1761 | /** | |
1762 | * Returns by pointer, unit of length: foot. | |
57a6839d | 1763 | * Caller owns returned value and must free it. |
3d1f044b | 1764 | * Also see {@link #getFoot()}. |
57a6839d | 1765 | * @param status ICU error code. |
b331163b | 1766 | * @stable ICU 53 |
57a6839d | 1767 | */ |
b331163b | 1768 | static MeasureUnit *createFoot(UErrorCode &status); |
57a6839d | 1769 | |
3d1f044b A |
1770 | #ifndef U_HIDE_DRAFT_API |
1771 | /** | |
1772 | * Returns by value, unit of length: foot. | |
1773 | * Also see {@link #createFoot()}. | |
1774 | * @draft ICU 64 | |
1775 | */ | |
1776 | static MeasureUnit getFoot(); | |
1777 | #endif /* U_HIDE_DRAFT_API */ | |
1778 | ||
57a6839d | 1779 | /** |
3d1f044b | 1780 | * Returns by pointer, unit of length: furlong. |
57a6839d | 1781 | * Caller owns returned value and must free it. |
3d1f044b | 1782 | * Also see {@link #getFurlong()}. |
57a6839d | 1783 | * @param status ICU error code. |
2ca993e8 | 1784 | * @stable ICU 54 |
57a6839d | 1785 | */ |
b331163b | 1786 | static MeasureUnit *createFurlong(UErrorCode &status); |
57a6839d | 1787 | |
3d1f044b A |
1788 | #ifndef U_HIDE_DRAFT_API |
1789 | /** | |
1790 | * Returns by value, unit of length: furlong. | |
1791 | * Also see {@link #createFurlong()}. | |
1792 | * @draft ICU 64 | |
1793 | */ | |
1794 | static MeasureUnit getFurlong(); | |
1795 | #endif /* U_HIDE_DRAFT_API */ | |
1796 | ||
57a6839d | 1797 | /** |
3d1f044b | 1798 | * Returns by pointer, unit of length: inch. |
57a6839d | 1799 | * Caller owns returned value and must free it. |
3d1f044b | 1800 | * Also see {@link #getInch()}. |
57a6839d | 1801 | * @param status ICU error code. |
b331163b | 1802 | * @stable ICU 53 |
57a6839d | 1803 | */ |
b331163b | 1804 | static MeasureUnit *createInch(UErrorCode &status); |
57a6839d | 1805 | |
3d1f044b | 1806 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 1807 | /** |
3d1f044b A |
1808 | * Returns by value, unit of length: inch. |
1809 | * Also see {@link #createInch()}. | |
1810 | * @draft ICU 64 | |
1811 | */ | |
1812 | static MeasureUnit getInch(); | |
1813 | #endif /* U_HIDE_DRAFT_API */ | |
1814 | ||
1815 | /** | |
1816 | * Returns by pointer, unit of length: kilometer. | |
57a6839d | 1817 | * Caller owns returned value and must free it. |
3d1f044b | 1818 | * Also see {@link #getKilometer()}. |
57a6839d | 1819 | * @param status ICU error code. |
b331163b | 1820 | * @stable ICU 53 |
57a6839d | 1821 | */ |
b331163b | 1822 | static MeasureUnit *createKilometer(UErrorCode &status); |
57a6839d | 1823 | |
3d1f044b A |
1824 | #ifndef U_HIDE_DRAFT_API |
1825 | /** | |
1826 | * Returns by value, unit of length: kilometer. | |
1827 | * Also see {@link #createKilometer()}. | |
1828 | * @draft ICU 64 | |
1829 | */ | |
1830 | static MeasureUnit getKilometer(); | |
1831 | #endif /* U_HIDE_DRAFT_API */ | |
1832 | ||
57a6839d | 1833 | /** |
3d1f044b | 1834 | * Returns by pointer, unit of length: light-year. |
57a6839d | 1835 | * Caller owns returned value and must free it. |
3d1f044b | 1836 | * Also see {@link #getLightYear()}. |
57a6839d | 1837 | * @param status ICU error code. |
b331163b | 1838 | * @stable ICU 53 |
57a6839d | 1839 | */ |
b331163b | 1840 | static MeasureUnit *createLightYear(UErrorCode &status); |
57a6839d | 1841 | |
3d1f044b | 1842 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 1843 | /** |
3d1f044b A |
1844 | * Returns by value, unit of length: light-year. |
1845 | * Also see {@link #createLightYear()}. | |
1846 | * @draft ICU 64 | |
1847 | */ | |
1848 | static MeasureUnit getLightYear(); | |
1849 | #endif /* U_HIDE_DRAFT_API */ | |
1850 | ||
1851 | /** | |
1852 | * Returns by pointer, unit of length: meter. | |
57a6839d | 1853 | * Caller owns returned value and must free it. |
3d1f044b | 1854 | * Also see {@link #getMeter()}. |
57a6839d | 1855 | * @param status ICU error code. |
b331163b | 1856 | * @stable ICU 53 |
57a6839d | 1857 | */ |
b331163b | 1858 | static MeasureUnit *createMeter(UErrorCode &status); |
57a6839d | 1859 | |
3d1f044b A |
1860 | #ifndef U_HIDE_DRAFT_API |
1861 | /** | |
1862 | * Returns by value, unit of length: meter. | |
1863 | * Also see {@link #createMeter()}. | |
1864 | * @draft ICU 64 | |
1865 | */ | |
1866 | static MeasureUnit getMeter(); | |
1867 | #endif /* U_HIDE_DRAFT_API */ | |
1868 | ||
57a6839d | 1869 | /** |
3d1f044b | 1870 | * Returns by pointer, unit of length: micrometer. |
57a6839d | 1871 | * Caller owns returned value and must free it. |
3d1f044b | 1872 | * Also see {@link #getMicrometer()}. |
57a6839d | 1873 | * @param status ICU error code. |
2ca993e8 | 1874 | * @stable ICU 54 |
57a6839d | 1875 | */ |
b331163b | 1876 | static MeasureUnit *createMicrometer(UErrorCode &status); |
57a6839d | 1877 | |
3d1f044b | 1878 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 1879 | /** |
3d1f044b A |
1880 | * Returns by value, unit of length: micrometer. |
1881 | * Also see {@link #createMicrometer()}. | |
1882 | * @draft ICU 64 | |
1883 | */ | |
1884 | static MeasureUnit getMicrometer(); | |
1885 | #endif /* U_HIDE_DRAFT_API */ | |
1886 | ||
1887 | /** | |
1888 | * Returns by pointer, unit of length: mile. | |
57a6839d | 1889 | * Caller owns returned value and must free it. |
3d1f044b | 1890 | * Also see {@link #getMile()}. |
57a6839d | 1891 | * @param status ICU error code. |
b331163b | 1892 | * @stable ICU 53 |
57a6839d | 1893 | */ |
b331163b | 1894 | static MeasureUnit *createMile(UErrorCode &status); |
57a6839d | 1895 | |
3d1f044b A |
1896 | #ifndef U_HIDE_DRAFT_API |
1897 | /** | |
1898 | * Returns by value, unit of length: mile. | |
1899 | * Also see {@link #createMile()}. | |
1900 | * @draft ICU 64 | |
1901 | */ | |
1902 | static MeasureUnit getMile(); | |
1903 | #endif /* U_HIDE_DRAFT_API */ | |
1904 | ||
2ca993e8 | 1905 | /** |
3d1f044b | 1906 | * Returns by pointer, unit of length: mile-scandinavian. |
2ca993e8 | 1907 | * Caller owns returned value and must free it. |
3d1f044b | 1908 | * Also see {@link #getMileScandinavian()}. |
2ca993e8 | 1909 | * @param status ICU error code. |
f3c0d7a5 | 1910 | * @stable ICU 56 |
2ca993e8 A |
1911 | */ |
1912 | static MeasureUnit *createMileScandinavian(UErrorCode &status); | |
2ca993e8 | 1913 | |
3d1f044b | 1914 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 1915 | /** |
3d1f044b A |
1916 | * Returns by value, unit of length: mile-scandinavian. |
1917 | * Also see {@link #createMileScandinavian()}. | |
1918 | * @draft ICU 64 | |
1919 | */ | |
1920 | static MeasureUnit getMileScandinavian(); | |
1921 | #endif /* U_HIDE_DRAFT_API */ | |
1922 | ||
1923 | /** | |
1924 | * Returns by pointer, unit of length: millimeter. | |
57a6839d | 1925 | * Caller owns returned value and must free it. |
3d1f044b | 1926 | * Also see {@link #getMillimeter()}. |
57a6839d | 1927 | * @param status ICU error code. |
b331163b | 1928 | * @stable ICU 53 |
57a6839d | 1929 | */ |
3d1f044b A |
1930 | static MeasureUnit *createMillimeter(UErrorCode &status); |
1931 | ||
1932 | #ifndef U_HIDE_DRAFT_API | |
1933 | /** | |
1934 | * Returns by value, unit of length: millimeter. | |
1935 | * Also see {@link #createMillimeter()}. | |
1936 | * @draft ICU 64 | |
1937 | */ | |
1938 | static MeasureUnit getMillimeter(); | |
1939 | #endif /* U_HIDE_DRAFT_API */ | |
1940 | ||
1941 | /** | |
1942 | * Returns by pointer, unit of length: nanometer. | |
1943 | * Caller owns returned value and must free it. | |
1944 | * Also see {@link #getNanometer()}. | |
1945 | * @param status ICU error code. | |
1946 | * @stable ICU 54 | |
1947 | */ | |
1948 | static MeasureUnit *createNanometer(UErrorCode &status); | |
1949 | ||
1950 | #ifndef U_HIDE_DRAFT_API | |
1951 | /** | |
1952 | * Returns by value, unit of length: nanometer. | |
1953 | * Also see {@link #createNanometer()}. | |
1954 | * @draft ICU 64 | |
1955 | */ | |
1956 | static MeasureUnit getNanometer(); | |
1957 | #endif /* U_HIDE_DRAFT_API */ | |
1958 | ||
1959 | /** | |
1960 | * Returns by pointer, unit of length: nautical-mile. | |
1961 | * Caller owns returned value and must free it. | |
1962 | * Also see {@link #getNauticalMile()}. | |
1963 | * @param status ICU error code. | |
1964 | * @stable ICU 54 | |
1965 | */ | |
1966 | static MeasureUnit *createNauticalMile(UErrorCode &status); | |
1967 | ||
1968 | #ifndef U_HIDE_DRAFT_API | |
1969 | /** | |
1970 | * Returns by value, unit of length: nautical-mile. | |
1971 | * Also see {@link #createNauticalMile()}. | |
1972 | * @draft ICU 64 | |
1973 | */ | |
1974 | static MeasureUnit getNauticalMile(); | |
1975 | #endif /* U_HIDE_DRAFT_API */ | |
1976 | ||
1977 | /** | |
1978 | * Returns by pointer, unit of length: parsec. | |
1979 | * Caller owns returned value and must free it. | |
1980 | * Also see {@link #getParsec()}. | |
1981 | * @param status ICU error code. | |
1982 | * @stable ICU 54 | |
1983 | */ | |
1984 | static MeasureUnit *createParsec(UErrorCode &status); | |
1985 | ||
1986 | #ifndef U_HIDE_DRAFT_API | |
1987 | /** | |
1988 | * Returns by value, unit of length: parsec. | |
1989 | * Also see {@link #createParsec()}. | |
1990 | * @draft ICU 64 | |
1991 | */ | |
1992 | static MeasureUnit getParsec(); | |
1993 | #endif /* U_HIDE_DRAFT_API */ | |
1994 | ||
1995 | /** | |
1996 | * Returns by pointer, unit of length: picometer. | |
1997 | * Caller owns returned value and must free it. | |
1998 | * Also see {@link #getPicometer()}. | |
1999 | * @param status ICU error code. | |
2000 | * @stable ICU 53 | |
2001 | */ | |
2002 | static MeasureUnit *createPicometer(UErrorCode &status); | |
2003 | ||
2004 | #ifndef U_HIDE_DRAFT_API | |
2005 | /** | |
2006 | * Returns by value, unit of length: picometer. | |
2007 | * Also see {@link #createPicometer()}. | |
2008 | * @draft ICU 64 | |
2009 | */ | |
2010 | static MeasureUnit getPicometer(); | |
2011 | #endif /* U_HIDE_DRAFT_API */ | |
2012 | ||
2013 | /** | |
2014 | * Returns by pointer, unit of length: point. | |
2015 | * Caller owns returned value and must free it. | |
2016 | * Also see {@link #getPoint()}. | |
2017 | * @param status ICU error code. | |
2018 | * @stable ICU 59 | |
2019 | */ | |
2020 | static MeasureUnit *createPoint(UErrorCode &status); | |
2021 | ||
2022 | #ifndef U_HIDE_DRAFT_API | |
2023 | /** | |
2024 | * Returns by value, unit of length: point. | |
2025 | * Also see {@link #createPoint()}. | |
2026 | * @draft ICU 64 | |
2027 | */ | |
2028 | static MeasureUnit getPoint(); | |
2029 | #endif /* U_HIDE_DRAFT_API */ | |
2030 | ||
2031 | #ifndef U_HIDE_DRAFT_API | |
2032 | /** | |
2033 | * Returns by pointer, unit of length: solar-radius. | |
2034 | * Caller owns returned value and must free it. | |
2035 | * Also see {@link #getSolarRadius()}. | |
2036 | * @param status ICU error code. | |
2037 | * @draft ICU 64 | |
2038 | */ | |
2039 | static MeasureUnit *createSolarRadius(UErrorCode &status); | |
2040 | ||
2041 | /** | |
2042 | * Returns by value, unit of length: solar-radius. | |
2043 | * Also see {@link #createSolarRadius()}. | |
2044 | * @draft ICU 64 | |
2045 | */ | |
2046 | static MeasureUnit getSolarRadius(); | |
2047 | #endif /* U_HIDE_DRAFT_API */ | |
2048 | ||
2049 | /** | |
2050 | * Returns by pointer, unit of length: yard. | |
2051 | * Caller owns returned value and must free it. | |
2052 | * Also see {@link #getYard()}. | |
2053 | * @param status ICU error code. | |
2054 | * @stable ICU 53 | |
2055 | */ | |
2056 | static MeasureUnit *createYard(UErrorCode &status); | |
2057 | ||
2058 | #ifndef U_HIDE_DRAFT_API | |
2059 | /** | |
2060 | * Returns by value, unit of length: yard. | |
2061 | * Also see {@link #createYard()}. | |
2062 | * @draft ICU 64 | |
2063 | */ | |
2064 | static MeasureUnit getYard(); | |
2065 | #endif /* U_HIDE_DRAFT_API */ | |
57a6839d A |
2066 | |
2067 | /** | |
3d1f044b | 2068 | * Returns by pointer, unit of light: lux. |
57a6839d | 2069 | * Caller owns returned value and must free it. |
3d1f044b | 2070 | * Also see {@link #getLux()}. |
57a6839d | 2071 | * @param status ICU error code. |
2ca993e8 | 2072 | * @stable ICU 54 |
57a6839d | 2073 | */ |
3d1f044b | 2074 | static MeasureUnit *createLux(UErrorCode &status); |
57a6839d | 2075 | |
3d1f044b | 2076 | #ifndef U_HIDE_DRAFT_API |
57a6839d | 2077 | /** |
3d1f044b A |
2078 | * Returns by value, unit of light: lux. |
2079 | * Also see {@link #createLux()}. | |
2080 | * @draft ICU 64 | |
2081 | */ | |
2082 | static MeasureUnit getLux(); | |
2083 | #endif /* U_HIDE_DRAFT_API */ | |
2084 | ||
2085 | #ifndef U_HIDE_DRAFT_API | |
2086 | /** | |
2087 | * Returns by pointer, unit of light: solar-luminosity. | |
57a6839d | 2088 | * Caller owns returned value and must free it. |
3d1f044b | 2089 | * Also see {@link #getSolarLuminosity()}. |
57a6839d | 2090 | * @param status ICU error code. |
3d1f044b | 2091 | * @draft ICU 64 |
57a6839d | 2092 | */ |
3d1f044b A |
2093 | static MeasureUnit *createSolarLuminosity(UErrorCode &status); |
2094 | ||
2095 | /** | |
2096 | * Returns by value, unit of light: solar-luminosity. | |
2097 | * Also see {@link #createSolarLuminosity()}. | |
2098 | * @draft ICU 64 | |
2099 | */ | |
2100 | static MeasureUnit getSolarLuminosity(); | |
2101 | #endif /* U_HIDE_DRAFT_API */ | |
57a6839d A |
2102 | |
2103 | /** | |
3d1f044b | 2104 | * Returns by pointer, unit of mass: carat. |
57a6839d | 2105 | * Caller owns returned value and must free it. |
3d1f044b | 2106 | * Also see {@link #getCarat()}. |
57a6839d | 2107 | * @param status ICU error code. |
2ca993e8 | 2108 | * @stable ICU 54 |
57a6839d | 2109 | */ |
3d1f044b | 2110 | static MeasureUnit *createCarat(UErrorCode &status); |
b331163b | 2111 | |
3d1f044b | 2112 | #ifndef U_HIDE_DRAFT_API |
b331163b | 2113 | /** |
3d1f044b A |
2114 | * Returns by value, unit of mass: carat. |
2115 | * Also see {@link #createCarat()}. | |
2116 | * @draft ICU 64 | |
b331163b | 2117 | */ |
3d1f044b A |
2118 | static MeasureUnit getCarat(); |
2119 | #endif /* U_HIDE_DRAFT_API */ | |
b331163b | 2120 | |
3d1f044b | 2121 | #ifndef U_HIDE_DRAFT_API |
f3c0d7a5 | 2122 | /** |
3d1f044b | 2123 | * Returns by pointer, unit of mass: dalton. |
f3c0d7a5 | 2124 | * Caller owns returned value and must free it. |
3d1f044b | 2125 | * Also see {@link #getDalton()}. |
f3c0d7a5 | 2126 | * @param status ICU error code. |
3d1f044b | 2127 | * @draft ICU 64 |
f3c0d7a5 | 2128 | */ |
3d1f044b | 2129 | static MeasureUnit *createDalton(UErrorCode &status); |
f3c0d7a5 | 2130 | |
b331163b | 2131 | /** |
3d1f044b A |
2132 | * Returns by value, unit of mass: dalton. |
2133 | * Also see {@link #createDalton()}. | |
2134 | * @draft ICU 64 | |
b331163b | 2135 | */ |
3d1f044b A |
2136 | static MeasureUnit getDalton(); |
2137 | #endif /* U_HIDE_DRAFT_API */ | |
b331163b | 2138 | |
3d1f044b | 2139 | #ifndef U_HIDE_DRAFT_API |
b331163b | 2140 | /** |
3d1f044b | 2141 | * Returns by pointer, unit of mass: earth-mass. |
b331163b | 2142 | * Caller owns returned value and must free it. |
3d1f044b | 2143 | * Also see {@link #getEarthMass()}. |
b331163b | 2144 | * @param status ICU error code. |
3d1f044b | 2145 | * @draft ICU 64 |
b331163b | 2146 | */ |
3d1f044b | 2147 | static MeasureUnit *createEarthMass(UErrorCode &status); |
57a6839d | 2148 | |
b331163b | 2149 | /** |
3d1f044b A |
2150 | * Returns by value, unit of mass: earth-mass. |
2151 | * Also see {@link #createEarthMass()}. | |
2152 | * @draft ICU 64 | |
b331163b | 2153 | */ |
3d1f044b A |
2154 | static MeasureUnit getEarthMass(); |
2155 | #endif /* U_HIDE_DRAFT_API */ | |
b331163b | 2156 | |
b331163b | 2157 | /** |
3d1f044b | 2158 | * Returns by pointer, unit of mass: gram. |
b331163b | 2159 | * Caller owns returned value and must free it. |
3d1f044b | 2160 | * Also see {@link #getGram()}. |
b331163b A |
2161 | * @param status ICU error code. |
2162 | * @stable ICU 53 | |
2163 | */ | |
2164 | static MeasureUnit *createGram(UErrorCode &status); | |
2165 | ||
3d1f044b A |
2166 | #ifndef U_HIDE_DRAFT_API |
2167 | /** | |
2168 | * Returns by value, unit of mass: gram. | |
2169 | * Also see {@link #createGram()}. | |
2170 | * @draft ICU 64 | |
2171 | */ | |
2172 | static MeasureUnit getGram(); | |
2173 | #endif /* U_HIDE_DRAFT_API */ | |
2174 | ||
b331163b | 2175 | /** |
3d1f044b | 2176 | * Returns by pointer, unit of mass: kilogram. |
b331163b | 2177 | * Caller owns returned value and must free it. |
3d1f044b | 2178 | * Also see {@link #getKilogram()}. |
b331163b A |
2179 | * @param status ICU error code. |
2180 | * @stable ICU 53 | |
2181 | */ | |
2182 | static MeasureUnit *createKilogram(UErrorCode &status); | |
2183 | ||
3d1f044b A |
2184 | #ifndef U_HIDE_DRAFT_API |
2185 | /** | |
2186 | * Returns by value, unit of mass: kilogram. | |
2187 | * Also see {@link #createKilogram()}. | |
2188 | * @draft ICU 64 | |
2189 | */ | |
2190 | static MeasureUnit getKilogram(); | |
2191 | #endif /* U_HIDE_DRAFT_API */ | |
2192 | ||
b331163b | 2193 | /** |
3d1f044b | 2194 | * Returns by pointer, unit of mass: metric-ton. |
b331163b | 2195 | * Caller owns returned value and must free it. |
3d1f044b | 2196 | * Also see {@link #getMetricTon()}. |
b331163b | 2197 | * @param status ICU error code. |
2ca993e8 | 2198 | * @stable ICU 54 |
b331163b A |
2199 | */ |
2200 | static MeasureUnit *createMetricTon(UErrorCode &status); | |
2201 | ||
3d1f044b | 2202 | #ifndef U_HIDE_DRAFT_API |
b331163b | 2203 | /** |
3d1f044b A |
2204 | * Returns by value, unit of mass: metric-ton. |
2205 | * Also see {@link #createMetricTon()}. | |
2206 | * @draft ICU 64 | |
2207 | */ | |
2208 | static MeasureUnit getMetricTon(); | |
2209 | #endif /* U_HIDE_DRAFT_API */ | |
2210 | ||
2211 | /** | |
2212 | * Returns by pointer, unit of mass: microgram. | |
b331163b | 2213 | * Caller owns returned value and must free it. |
3d1f044b | 2214 | * Also see {@link #getMicrogram()}. |
b331163b | 2215 | * @param status ICU error code. |
2ca993e8 | 2216 | * @stable ICU 54 |
b331163b A |
2217 | */ |
2218 | static MeasureUnit *createMicrogram(UErrorCode &status); | |
2219 | ||
3d1f044b A |
2220 | #ifndef U_HIDE_DRAFT_API |
2221 | /** | |
2222 | * Returns by value, unit of mass: microgram. | |
2223 | * Also see {@link #createMicrogram()}. | |
2224 | * @draft ICU 64 | |
2225 | */ | |
2226 | static MeasureUnit getMicrogram(); | |
2227 | #endif /* U_HIDE_DRAFT_API */ | |
2228 | ||
b331163b | 2229 | /** |
3d1f044b | 2230 | * Returns by pointer, unit of mass: milligram. |
b331163b | 2231 | * Caller owns returned value and must free it. |
3d1f044b | 2232 | * Also see {@link #getMilligram()}. |
b331163b | 2233 | * @param status ICU error code. |
2ca993e8 | 2234 | * @stable ICU 54 |
b331163b A |
2235 | */ |
2236 | static MeasureUnit *createMilligram(UErrorCode &status); | |
2237 | ||
3d1f044b A |
2238 | #ifndef U_HIDE_DRAFT_API |
2239 | /** | |
2240 | * Returns by value, unit of mass: milligram. | |
2241 | * Also see {@link #createMilligram()}. | |
2242 | * @draft ICU 64 | |
2243 | */ | |
2244 | static MeasureUnit getMilligram(); | |
2245 | #endif /* U_HIDE_DRAFT_API */ | |
2246 | ||
b331163b | 2247 | /** |
3d1f044b | 2248 | * Returns by pointer, unit of mass: ounce. |
b331163b | 2249 | * Caller owns returned value and must free it. |
3d1f044b | 2250 | * Also see {@link #getOunce()}. |
b331163b A |
2251 | * @param status ICU error code. |
2252 | * @stable ICU 53 | |
2253 | */ | |
2254 | static MeasureUnit *createOunce(UErrorCode &status); | |
2255 | ||
3d1f044b A |
2256 | #ifndef U_HIDE_DRAFT_API |
2257 | /** | |
2258 | * Returns by value, unit of mass: ounce. | |
2259 | * Also see {@link #createOunce()}. | |
2260 | * @draft ICU 64 | |
2261 | */ | |
2262 | static MeasureUnit getOunce(); | |
2263 | #endif /* U_HIDE_DRAFT_API */ | |
2264 | ||
b331163b | 2265 | /** |
3d1f044b | 2266 | * Returns by pointer, unit of mass: ounce-troy. |
b331163b | 2267 | * Caller owns returned value and must free it. |
3d1f044b | 2268 | * Also see {@link #getOunceTroy()}. |
b331163b | 2269 | * @param status ICU error code. |
2ca993e8 | 2270 | * @stable ICU 54 |
b331163b A |
2271 | */ |
2272 | static MeasureUnit *createOunceTroy(UErrorCode &status); | |
2273 | ||
3d1f044b | 2274 | #ifndef U_HIDE_DRAFT_API |
b331163b | 2275 | /** |
3d1f044b A |
2276 | * Returns by value, unit of mass: ounce-troy. |
2277 | * Also see {@link #createOunceTroy()}. | |
2278 | * @draft ICU 64 | |
2279 | */ | |
2280 | static MeasureUnit getOunceTroy(); | |
2281 | #endif /* U_HIDE_DRAFT_API */ | |
2282 | ||
2283 | /** | |
2284 | * Returns by pointer, unit of mass: pound. | |
b331163b | 2285 | * Caller owns returned value and must free it. |
3d1f044b | 2286 | * Also see {@link #getPound()}. |
b331163b A |
2287 | * @param status ICU error code. |
2288 | * @stable ICU 53 | |
2289 | */ | |
2290 | static MeasureUnit *createPound(UErrorCode &status); | |
2291 | ||
3d1f044b A |
2292 | #ifndef U_HIDE_DRAFT_API |
2293 | /** | |
2294 | * Returns by value, unit of mass: pound. | |
2295 | * Also see {@link #createPound()}. | |
2296 | * @draft ICU 64 | |
2297 | */ | |
2298 | static MeasureUnit getPound(); | |
2299 | #endif /* U_HIDE_DRAFT_API */ | |
2300 | ||
2301 | #ifndef U_HIDE_DRAFT_API | |
2302 | /** | |
2303 | * Returns by pointer, unit of mass: solar-mass. | |
2304 | * Caller owns returned value and must free it. | |
2305 | * Also see {@link #getSolarMass()}. | |
2306 | * @param status ICU error code. | |
2307 | * @draft ICU 64 | |
2308 | */ | |
2309 | static MeasureUnit *createSolarMass(UErrorCode &status); | |
2310 | ||
2311 | /** | |
2312 | * Returns by value, unit of mass: solar-mass. | |
2313 | * Also see {@link #createSolarMass()}. | |
2314 | * @draft ICU 64 | |
2315 | */ | |
2316 | static MeasureUnit getSolarMass(); | |
2317 | #endif /* U_HIDE_DRAFT_API */ | |
2318 | ||
b331163b | 2319 | /** |
3d1f044b | 2320 | * Returns by pointer, unit of mass: stone. |
b331163b | 2321 | * Caller owns returned value and must free it. |
3d1f044b | 2322 | * Also see {@link #getStone()}. |
b331163b | 2323 | * @param status ICU error code. |
2ca993e8 | 2324 | * @stable ICU 54 |
b331163b A |
2325 | */ |
2326 | static MeasureUnit *createStone(UErrorCode &status); | |
2327 | ||
3d1f044b A |
2328 | #ifndef U_HIDE_DRAFT_API |
2329 | /** | |
2330 | * Returns by value, unit of mass: stone. | |
2331 | * Also see {@link #createStone()}. | |
2332 | * @draft ICU 64 | |
2333 | */ | |
2334 | static MeasureUnit getStone(); | |
2335 | #endif /* U_HIDE_DRAFT_API */ | |
2336 | ||
b331163b | 2337 | /** |
3d1f044b | 2338 | * Returns by pointer, unit of mass: ton. |
b331163b | 2339 | * Caller owns returned value and must free it. |
3d1f044b | 2340 | * Also see {@link #getTon()}. |
b331163b | 2341 | * @param status ICU error code. |
2ca993e8 | 2342 | * @stable ICU 54 |
b331163b A |
2343 | */ |
2344 | static MeasureUnit *createTon(UErrorCode &status); | |
2345 | ||
3d1f044b A |
2346 | #ifndef U_HIDE_DRAFT_API |
2347 | /** | |
2348 | * Returns by value, unit of mass: ton. | |
2349 | * Also see {@link #createTon()}. | |
2350 | * @draft ICU 64 | |
2351 | */ | |
2352 | static MeasureUnit getTon(); | |
2353 | #endif /* U_HIDE_DRAFT_API */ | |
2354 | ||
b331163b | 2355 | /** |
3d1f044b | 2356 | * Returns by pointer, unit of power: gigawatt. |
b331163b | 2357 | * Caller owns returned value and must free it. |
3d1f044b | 2358 | * Also see {@link #getGigawatt()}. |
b331163b | 2359 | * @param status ICU error code. |
2ca993e8 | 2360 | * @stable ICU 54 |
b331163b A |
2361 | */ |
2362 | static MeasureUnit *createGigawatt(UErrorCode &status); | |
2363 | ||
3d1f044b | 2364 | #ifndef U_HIDE_DRAFT_API |
b331163b | 2365 | /** |
3d1f044b A |
2366 | * Returns by value, unit of power: gigawatt. |
2367 | * Also see {@link #createGigawatt()}. | |
2368 | * @draft ICU 64 | |
2369 | */ | |
2370 | static MeasureUnit getGigawatt(); | |
2371 | #endif /* U_HIDE_DRAFT_API */ | |
2372 | ||
2373 | /** | |
2374 | * Returns by pointer, unit of power: horsepower. | |
b331163b | 2375 | * Caller owns returned value and must free it. |
3d1f044b | 2376 | * Also see {@link #getHorsepower()}. |
b331163b A |
2377 | * @param status ICU error code. |
2378 | * @stable ICU 53 | |
2379 | */ | |
2380 | static MeasureUnit *createHorsepower(UErrorCode &status); | |
2381 | ||
3d1f044b A |
2382 | #ifndef U_HIDE_DRAFT_API |
2383 | /** | |
2384 | * Returns by value, unit of power: horsepower. | |
2385 | * Also see {@link #createHorsepower()}. | |
2386 | * @draft ICU 64 | |
2387 | */ | |
2388 | static MeasureUnit getHorsepower(); | |
2389 | #endif /* U_HIDE_DRAFT_API */ | |
2390 | ||
b331163b | 2391 | /** |
3d1f044b | 2392 | * Returns by pointer, unit of power: kilowatt. |
b331163b | 2393 | * Caller owns returned value and must free it. |
3d1f044b | 2394 | * Also see {@link #getKilowatt()}. |
b331163b A |
2395 | * @param status ICU error code. |
2396 | * @stable ICU 53 | |
2397 | */ | |
2398 | static MeasureUnit *createKilowatt(UErrorCode &status); | |
2399 | ||
3d1f044b A |
2400 | #ifndef U_HIDE_DRAFT_API |
2401 | /** | |
2402 | * Returns by value, unit of power: kilowatt. | |
2403 | * Also see {@link #createKilowatt()}. | |
2404 | * @draft ICU 64 | |
2405 | */ | |
2406 | static MeasureUnit getKilowatt(); | |
2407 | #endif /* U_HIDE_DRAFT_API */ | |
2408 | ||
b331163b | 2409 | /** |
3d1f044b | 2410 | * Returns by pointer, unit of power: megawatt. |
b331163b | 2411 | * Caller owns returned value and must free it. |
3d1f044b | 2412 | * Also see {@link #getMegawatt()}. |
b331163b | 2413 | * @param status ICU error code. |
2ca993e8 | 2414 | * @stable ICU 54 |
b331163b A |
2415 | */ |
2416 | static MeasureUnit *createMegawatt(UErrorCode &status); | |
2417 | ||
3d1f044b A |
2418 | #ifndef U_HIDE_DRAFT_API |
2419 | /** | |
2420 | * Returns by value, unit of power: megawatt. | |
2421 | * Also see {@link #createMegawatt()}. | |
2422 | * @draft ICU 64 | |
2423 | */ | |
2424 | static MeasureUnit getMegawatt(); | |
2425 | #endif /* U_HIDE_DRAFT_API */ | |
2426 | ||
b331163b | 2427 | /** |
3d1f044b | 2428 | * Returns by pointer, unit of power: milliwatt. |
b331163b | 2429 | * Caller owns returned value and must free it. |
3d1f044b | 2430 | * Also see {@link #getMilliwatt()}. |
b331163b | 2431 | * @param status ICU error code. |
2ca993e8 | 2432 | * @stable ICU 54 |
b331163b A |
2433 | */ |
2434 | static MeasureUnit *createMilliwatt(UErrorCode &status); | |
2435 | ||
3d1f044b | 2436 | #ifndef U_HIDE_DRAFT_API |
b331163b | 2437 | /** |
3d1f044b A |
2438 | * Returns by value, unit of power: milliwatt. |
2439 | * Also see {@link #createMilliwatt()}. | |
2440 | * @draft ICU 64 | |
2441 | */ | |
2442 | static MeasureUnit getMilliwatt(); | |
2443 | #endif /* U_HIDE_DRAFT_API */ | |
2444 | ||
2445 | /** | |
2446 | * Returns by pointer, unit of power: watt. | |
b331163b | 2447 | * Caller owns returned value and must free it. |
3d1f044b | 2448 | * Also see {@link #getWatt()}. |
b331163b A |
2449 | * @param status ICU error code. |
2450 | * @stable ICU 53 | |
2451 | */ | |
2452 | static MeasureUnit *createWatt(UErrorCode &status); | |
2453 | ||
3d1f044b A |
2454 | #ifndef U_HIDE_DRAFT_API |
2455 | /** | |
2456 | * Returns by value, unit of power: watt. | |
2457 | * Also see {@link #createWatt()}. | |
2458 | * @draft ICU 64 | |
2459 | */ | |
2460 | static MeasureUnit getWatt(); | |
2461 | #endif /* U_HIDE_DRAFT_API */ | |
2462 | ||
3d1f044b A |
2463 | /** |
2464 | * Returns by pointer, unit of pressure: atmosphere. | |
2465 | * Caller owns returned value and must free it. | |
2466 | * Also see {@link #getAtmosphere()}. | |
2467 | * @param status ICU error code. | |
340931cb | 2468 | * @stable ICU 63 |
3d1f044b A |
2469 | */ |
2470 | static MeasureUnit *createAtmosphere(UErrorCode &status); | |
3d1f044b A |
2471 | |
2472 | #ifndef U_HIDE_DRAFT_API | |
2473 | /** | |
2474 | * Returns by value, unit of pressure: atmosphere. | |
2475 | * Also see {@link #createAtmosphere()}. | |
2476 | * @draft ICU 64 | |
2477 | */ | |
2478 | static MeasureUnit getAtmosphere(); | |
2479 | #endif /* U_HIDE_DRAFT_API */ | |
2480 | ||
340931cb A |
2481 | #ifndef U_HIDE_DRAFT_API |
2482 | /** | |
2483 | * Returns by pointer, unit of pressure: bar. | |
2484 | * Caller owns returned value and must free it. | |
2485 | * Also see {@link #getBar()}. | |
2486 | * @param status ICU error code. | |
2487 | * @draft ICU 65 | |
2488 | */ | |
2489 | static MeasureUnit *createBar(UErrorCode &status); | |
2490 | ||
2491 | /** | |
2492 | * Returns by value, unit of pressure: bar. | |
2493 | * Also see {@link #createBar()}. | |
2494 | * @draft ICU 65 | |
2495 | */ | |
2496 | static MeasureUnit getBar(); | |
2497 | #endif /* U_HIDE_DRAFT_API */ | |
2498 | ||
b331163b | 2499 | /** |
3d1f044b | 2500 | * Returns by pointer, unit of pressure: hectopascal. |
b331163b | 2501 | * Caller owns returned value and must free it. |
3d1f044b | 2502 | * Also see {@link #getHectopascal()}. |
b331163b A |
2503 | * @param status ICU error code. |
2504 | * @stable ICU 53 | |
2505 | */ | |
2506 | static MeasureUnit *createHectopascal(UErrorCode &status); | |
2507 | ||
3d1f044b A |
2508 | #ifndef U_HIDE_DRAFT_API |
2509 | /** | |
2510 | * Returns by value, unit of pressure: hectopascal. | |
2511 | * Also see {@link #createHectopascal()}. | |
2512 | * @draft ICU 64 | |
2513 | */ | |
2514 | static MeasureUnit getHectopascal(); | |
2515 | #endif /* U_HIDE_DRAFT_API */ | |
2516 | ||
b331163b | 2517 | /** |
3d1f044b | 2518 | * Returns by pointer, unit of pressure: inch-hg. |
b331163b | 2519 | * Caller owns returned value and must free it. |
3d1f044b | 2520 | * Also see {@link #getInchHg()}. |
b331163b A |
2521 | * @param status ICU error code. |
2522 | * @stable ICU 53 | |
2523 | */ | |
2524 | static MeasureUnit *createInchHg(UErrorCode &status); | |
2525 | ||
3d1f044b A |
2526 | #ifndef U_HIDE_DRAFT_API |
2527 | /** | |
2528 | * Returns by value, unit of pressure: inch-hg. | |
2529 | * Also see {@link #createInchHg()}. | |
2530 | * @draft ICU 64 | |
2531 | */ | |
2532 | static MeasureUnit getInchHg(); | |
2533 | #endif /* U_HIDE_DRAFT_API */ | |
2534 | ||
2535 | #ifndef U_HIDE_DRAFT_API | |
2536 | /** | |
2537 | * Returns by pointer, unit of pressure: kilopascal. | |
2538 | * Caller owns returned value and must free it. | |
2539 | * Also see {@link #getKilopascal()}. | |
2540 | * @param status ICU error code. | |
2541 | * @draft ICU 64 | |
2542 | */ | |
2543 | static MeasureUnit *createKilopascal(UErrorCode &status); | |
2544 | ||
2545 | /** | |
2546 | * Returns by value, unit of pressure: kilopascal. | |
2547 | * Also see {@link #createKilopascal()}. | |
2548 | * @draft ICU 64 | |
2549 | */ | |
2550 | static MeasureUnit getKilopascal(); | |
2551 | #endif /* U_HIDE_DRAFT_API */ | |
2552 | ||
2553 | #ifndef U_HIDE_DRAFT_API | |
2554 | /** | |
2555 | * Returns by pointer, unit of pressure: megapascal. | |
2556 | * Caller owns returned value and must free it. | |
2557 | * Also see {@link #getMegapascal()}. | |
2558 | * @param status ICU error code. | |
2559 | * @draft ICU 64 | |
2560 | */ | |
2561 | static MeasureUnit *createMegapascal(UErrorCode &status); | |
2562 | ||
2563 | /** | |
2564 | * Returns by value, unit of pressure: megapascal. | |
2565 | * Also see {@link #createMegapascal()}. | |
2566 | * @draft ICU 64 | |
2567 | */ | |
2568 | static MeasureUnit getMegapascal(); | |
2569 | #endif /* U_HIDE_DRAFT_API */ | |
2570 | ||
b331163b | 2571 | /** |
3d1f044b | 2572 | * Returns by pointer, unit of pressure: millibar. |
b331163b | 2573 | * Caller owns returned value and must free it. |
3d1f044b | 2574 | * Also see {@link #getMillibar()}. |
b331163b A |
2575 | * @param status ICU error code. |
2576 | * @stable ICU 53 | |
2577 | */ | |
2578 | static MeasureUnit *createMillibar(UErrorCode &status); | |
2579 | ||
3d1f044b | 2580 | #ifndef U_HIDE_DRAFT_API |
b331163b | 2581 | /** |
3d1f044b A |
2582 | * Returns by value, unit of pressure: millibar. |
2583 | * Also see {@link #createMillibar()}. | |
2584 | * @draft ICU 64 | |
2585 | */ | |
2586 | static MeasureUnit getMillibar(); | |
2587 | #endif /* U_HIDE_DRAFT_API */ | |
2588 | ||
2589 | /** | |
2590 | * Returns by pointer, unit of pressure: millimeter-of-mercury. | |
b331163b | 2591 | * Caller owns returned value and must free it. |
3d1f044b | 2592 | * Also see {@link #getMillimeterOfMercury()}. |
b331163b | 2593 | * @param status ICU error code. |
2ca993e8 | 2594 | * @stable ICU 54 |
b331163b A |
2595 | */ |
2596 | static MeasureUnit *createMillimeterOfMercury(UErrorCode &status); | |
2597 | ||
3d1f044b A |
2598 | #ifndef U_HIDE_DRAFT_API |
2599 | /** | |
2600 | * Returns by value, unit of pressure: millimeter-of-mercury. | |
2601 | * Also see {@link #createMillimeterOfMercury()}. | |
2602 | * @draft ICU 64 | |
2603 | */ | |
2604 | static MeasureUnit getMillimeterOfMercury(); | |
2605 | #endif /* U_HIDE_DRAFT_API */ | |
2606 | ||
340931cb A |
2607 | #ifndef U_HIDE_DRAFT_API |
2608 | /** | |
2609 | * Returns by pointer, unit of pressure: pascal. | |
2610 | * Caller owns returned value and must free it. | |
2611 | * Also see {@link #getPascal()}. | |
2612 | * @param status ICU error code. | |
2613 | * @draft ICU 65 | |
2614 | */ | |
2615 | static MeasureUnit *createPascal(UErrorCode &status); | |
2616 | ||
2617 | /** | |
2618 | * Returns by value, unit of pressure: pascal. | |
2619 | * Also see {@link #createPascal()}. | |
2620 | * @draft ICU 65 | |
2621 | */ | |
2622 | static MeasureUnit getPascal(); | |
2623 | #endif /* U_HIDE_DRAFT_API */ | |
2624 | ||
b331163b | 2625 | /** |
3d1f044b | 2626 | * Returns by pointer, unit of pressure: pound-per-square-inch. |
b331163b | 2627 | * Caller owns returned value and must free it. |
3d1f044b | 2628 | * Also see {@link #getPoundPerSquareInch()}. |
b331163b | 2629 | * @param status ICU error code. |
2ca993e8 | 2630 | * @stable ICU 54 |
b331163b A |
2631 | */ |
2632 | static MeasureUnit *createPoundPerSquareInch(UErrorCode &status); | |
2633 | ||
3d1f044b A |
2634 | #ifndef U_HIDE_DRAFT_API |
2635 | /** | |
2636 | * Returns by value, unit of pressure: pound-per-square-inch. | |
2637 | * Also see {@link #createPoundPerSquareInch()}. | |
2638 | * @draft ICU 64 | |
2639 | */ | |
2640 | static MeasureUnit getPoundPerSquareInch(); | |
2641 | #endif /* U_HIDE_DRAFT_API */ | |
2642 | ||
b331163b | 2643 | /** |
3d1f044b | 2644 | * Returns by pointer, unit of speed: kilometer-per-hour. |
b331163b | 2645 | * Caller owns returned value and must free it. |
3d1f044b | 2646 | * Also see {@link #getKilometerPerHour()}. |
b331163b | 2647 | * @param status ICU error code. |
2ca993e8 | 2648 | * @stable ICU 53 |
b331163b | 2649 | */ |
2ca993e8 | 2650 | static MeasureUnit *createKilometerPerHour(UErrorCode &status); |
b331163b | 2651 | |
3d1f044b A |
2652 | #ifndef U_HIDE_DRAFT_API |
2653 | /** | |
2654 | * Returns by value, unit of speed: kilometer-per-hour. | |
2655 | * Also see {@link #createKilometerPerHour()}. | |
2656 | * @draft ICU 64 | |
2657 | */ | |
2658 | static MeasureUnit getKilometerPerHour(); | |
2659 | #endif /* U_HIDE_DRAFT_API */ | |
2660 | ||
b331163b | 2661 | /** |
3d1f044b | 2662 | * Returns by pointer, unit of speed: knot. |
b331163b | 2663 | * Caller owns returned value and must free it. |
3d1f044b | 2664 | * Also see {@link #getKnot()}. |
b331163b | 2665 | * @param status ICU error code. |
f3c0d7a5 | 2666 | * @stable ICU 56 |
b331163b | 2667 | */ |
2ca993e8 | 2668 | static MeasureUnit *createKnot(UErrorCode &status); |
b331163b | 2669 | |
3d1f044b | 2670 | #ifndef U_HIDE_DRAFT_API |
b331163b | 2671 | /** |
3d1f044b A |
2672 | * Returns by value, unit of speed: knot. |
2673 | * Also see {@link #createKnot()}. | |
2674 | * @draft ICU 64 | |
2675 | */ | |
2676 | static MeasureUnit getKnot(); | |
2677 | #endif /* U_HIDE_DRAFT_API */ | |
2678 | ||
2679 | /** | |
2680 | * Returns by pointer, unit of speed: meter-per-second. | |
b331163b | 2681 | * Caller owns returned value and must free it. |
3d1f044b | 2682 | * Also see {@link #getMeterPerSecond()}. |
b331163b A |
2683 | * @param status ICU error code. |
2684 | * @stable ICU 53 | |
2685 | */ | |
2686 | static MeasureUnit *createMeterPerSecond(UErrorCode &status); | |
2687 | ||
3d1f044b A |
2688 | #ifndef U_HIDE_DRAFT_API |
2689 | /** | |
2690 | * Returns by value, unit of speed: meter-per-second. | |
2691 | * Also see {@link #createMeterPerSecond()}. | |
2692 | * @draft ICU 64 | |
2693 | */ | |
2694 | static MeasureUnit getMeterPerSecond(); | |
2695 | #endif /* U_HIDE_DRAFT_API */ | |
2696 | ||
b331163b | 2697 | /** |
3d1f044b | 2698 | * Returns by pointer, unit of speed: mile-per-hour. |
b331163b | 2699 | * Caller owns returned value and must free it. |
3d1f044b | 2700 | * Also see {@link #getMilePerHour()}. |
b331163b A |
2701 | * @param status ICU error code. |
2702 | * @stable ICU 53 | |
2703 | */ | |
2704 | static MeasureUnit *createMilePerHour(UErrorCode &status); | |
2705 | ||
3d1f044b A |
2706 | #ifndef U_HIDE_DRAFT_API |
2707 | /** | |
2708 | * Returns by value, unit of speed: mile-per-hour. | |
2709 | * Also see {@link #createMilePerHour()}. | |
2710 | * @draft ICU 64 | |
2711 | */ | |
2712 | static MeasureUnit getMilePerHour(); | |
2713 | #endif /* U_HIDE_DRAFT_API */ | |
2714 | ||
b331163b | 2715 | /** |
3d1f044b | 2716 | * Returns by pointer, unit of temperature: celsius. |
b331163b | 2717 | * Caller owns returned value and must free it. |
3d1f044b | 2718 | * Also see {@link #getCelsius()}. |
b331163b A |
2719 | * @param status ICU error code. |
2720 | * @stable ICU 53 | |
2721 | */ | |
2722 | static MeasureUnit *createCelsius(UErrorCode &status); | |
2723 | ||
3d1f044b A |
2724 | #ifndef U_HIDE_DRAFT_API |
2725 | /** | |
2726 | * Returns by value, unit of temperature: celsius. | |
2727 | * Also see {@link #createCelsius()}. | |
2728 | * @draft ICU 64 | |
2729 | */ | |
2730 | static MeasureUnit getCelsius(); | |
2731 | #endif /* U_HIDE_DRAFT_API */ | |
2732 | ||
b331163b | 2733 | /** |
3d1f044b | 2734 | * Returns by pointer, unit of temperature: fahrenheit. |
b331163b | 2735 | * Caller owns returned value and must free it. |
3d1f044b | 2736 | * Also see {@link #getFahrenheit()}. |
b331163b A |
2737 | * @param status ICU error code. |
2738 | * @stable ICU 53 | |
2739 | */ | |
2740 | static MeasureUnit *createFahrenheit(UErrorCode &status); | |
2741 | ||
3d1f044b | 2742 | #ifndef U_HIDE_DRAFT_API |
b331163b | 2743 | /** |
3d1f044b A |
2744 | * Returns by value, unit of temperature: fahrenheit. |
2745 | * Also see {@link #createFahrenheit()}. | |
2746 | * @draft ICU 64 | |
2747 | */ | |
2748 | static MeasureUnit getFahrenheit(); | |
2749 | #endif /* U_HIDE_DRAFT_API */ | |
2750 | ||
2751 | /** | |
2752 | * Returns by pointer, unit of temperature: generic. | |
b331163b | 2753 | * Caller owns returned value and must free it. |
3d1f044b | 2754 | * Also see {@link #getGenericTemperature()}. |
b331163b | 2755 | * @param status ICU error code. |
f3c0d7a5 | 2756 | * @stable ICU 56 |
b331163b | 2757 | */ |
2ca993e8 | 2758 | static MeasureUnit *createGenericTemperature(UErrorCode &status); |
b331163b | 2759 | |
3d1f044b A |
2760 | #ifndef U_HIDE_DRAFT_API |
2761 | /** | |
2762 | * Returns by value, unit of temperature: generic. | |
2763 | * Also see {@link #createGenericTemperature()}. | |
2764 | * @draft ICU 64 | |
2765 | */ | |
2766 | static MeasureUnit getGenericTemperature(); | |
2767 | #endif /* U_HIDE_DRAFT_API */ | |
2768 | ||
b331163b | 2769 | /** |
3d1f044b | 2770 | * Returns by pointer, unit of temperature: kelvin. |
b331163b | 2771 | * Caller owns returned value and must free it. |
3d1f044b | 2772 | * Also see {@link #getKelvin()}. |
b331163b | 2773 | * @param status ICU error code. |
2ca993e8 | 2774 | * @stable ICU 54 |
b331163b | 2775 | */ |
2ca993e8 | 2776 | static MeasureUnit *createKelvin(UErrorCode &status); |
b331163b | 2777 | |
3d1f044b A |
2778 | #ifndef U_HIDE_DRAFT_API |
2779 | /** | |
2780 | * Returns by value, unit of temperature: kelvin. | |
2781 | * Also see {@link #createKelvin()}. | |
2782 | * @draft ICU 64 | |
2783 | */ | |
2784 | static MeasureUnit getKelvin(); | |
2785 | #endif /* U_HIDE_DRAFT_API */ | |
2786 | ||
2787 | #ifndef U_HIDE_DRAFT_API | |
2788 | /** | |
2789 | * Returns by pointer, unit of torque: newton-meter. | |
2790 | * Caller owns returned value and must free it. | |
2791 | * Also see {@link #getNewtonMeter()}. | |
2792 | * @param status ICU error code. | |
2793 | * @draft ICU 64 | |
2794 | */ | |
2795 | static MeasureUnit *createNewtonMeter(UErrorCode &status); | |
2796 | ||
2797 | /** | |
2798 | * Returns by value, unit of torque: newton-meter. | |
2799 | * Also see {@link #createNewtonMeter()}. | |
2800 | * @draft ICU 64 | |
2801 | */ | |
2802 | static MeasureUnit getNewtonMeter(); | |
2803 | #endif /* U_HIDE_DRAFT_API */ | |
2804 | ||
2805 | #ifndef U_HIDE_DRAFT_API | |
2806 | /** | |
2807 | * Returns by pointer, unit of torque: pound-foot. | |
2808 | * Caller owns returned value and must free it. | |
2809 | * Also see {@link #getPoundFoot()}. | |
2810 | * @param status ICU error code. | |
2811 | * @draft ICU 64 | |
2812 | */ | |
2813 | static MeasureUnit *createPoundFoot(UErrorCode &status); | |
2814 | ||
2815 | /** | |
2816 | * Returns by value, unit of torque: pound-foot. | |
2817 | * Also see {@link #createPoundFoot()}. | |
2818 | * @draft ICU 64 | |
2819 | */ | |
2820 | static MeasureUnit getPoundFoot(); | |
2821 | #endif /* U_HIDE_DRAFT_API */ | |
2822 | ||
b331163b | 2823 | /** |
3d1f044b | 2824 | * Returns by pointer, unit of volume: acre-foot. |
b331163b | 2825 | * Caller owns returned value and must free it. |
3d1f044b | 2826 | * Also see {@link #getAcreFoot()}. |
b331163b | 2827 | * @param status ICU error code. |
2ca993e8 | 2828 | * @stable ICU 54 |
b331163b A |
2829 | */ |
2830 | static MeasureUnit *createAcreFoot(UErrorCode &status); | |
2831 | ||
3d1f044b A |
2832 | #ifndef U_HIDE_DRAFT_API |
2833 | /** | |
2834 | * Returns by value, unit of volume: acre-foot. | |
2835 | * Also see {@link #createAcreFoot()}. | |
2836 | * @draft ICU 64 | |
2837 | */ | |
2838 | static MeasureUnit getAcreFoot(); | |
2839 | #endif /* U_HIDE_DRAFT_API */ | |
2840 | ||
2841 | #ifndef U_HIDE_DRAFT_API | |
2842 | /** | |
2843 | * Returns by pointer, unit of volume: barrel. | |
2844 | * Caller owns returned value and must free it. | |
2845 | * Also see {@link #getBarrel()}. | |
2846 | * @param status ICU error code. | |
2847 | * @draft ICU 64 | |
2848 | */ | |
2849 | static MeasureUnit *createBarrel(UErrorCode &status); | |
2850 | ||
2851 | /** | |
2852 | * Returns by value, unit of volume: barrel. | |
2853 | * Also see {@link #createBarrel()}. | |
2854 | * @draft ICU 64 | |
2855 | */ | |
2856 | static MeasureUnit getBarrel(); | |
2857 | #endif /* U_HIDE_DRAFT_API */ | |
2858 | ||
b331163b | 2859 | /** |
3d1f044b | 2860 | * Returns by pointer, unit of volume: bushel. |
b331163b | 2861 | * Caller owns returned value and must free it. |
3d1f044b | 2862 | * Also see {@link #getBushel()}. |
b331163b | 2863 | * @param status ICU error code. |
2ca993e8 | 2864 | * @stable ICU 54 |
b331163b A |
2865 | */ |
2866 | static MeasureUnit *createBushel(UErrorCode &status); | |
2867 | ||
3d1f044b | 2868 | #ifndef U_HIDE_DRAFT_API |
b331163b | 2869 | /** |
3d1f044b A |
2870 | * Returns by value, unit of volume: bushel. |
2871 | * Also see {@link #createBushel()}. | |
2872 | * @draft ICU 64 | |
2873 | */ | |
2874 | static MeasureUnit getBushel(); | |
2875 | #endif /* U_HIDE_DRAFT_API */ | |
2876 | ||
2877 | /** | |
2878 | * Returns by pointer, unit of volume: centiliter. | |
b331163b | 2879 | * Caller owns returned value and must free it. |
3d1f044b | 2880 | * Also see {@link #getCentiliter()}. |
b331163b | 2881 | * @param status ICU error code. |
2ca993e8 | 2882 | * @stable ICU 54 |
b331163b A |
2883 | */ |
2884 | static MeasureUnit *createCentiliter(UErrorCode &status); | |
2885 | ||
3d1f044b A |
2886 | #ifndef U_HIDE_DRAFT_API |
2887 | /** | |
2888 | * Returns by value, unit of volume: centiliter. | |
2889 | * Also see {@link #createCentiliter()}. | |
2890 | * @draft ICU 64 | |
2891 | */ | |
2892 | static MeasureUnit getCentiliter(); | |
2893 | #endif /* U_HIDE_DRAFT_API */ | |
2894 | ||
b331163b | 2895 | /** |
3d1f044b | 2896 | * Returns by pointer, unit of volume: cubic-centimeter. |
b331163b | 2897 | * Caller owns returned value and must free it. |
3d1f044b | 2898 | * Also see {@link #getCubicCentimeter()}. |
b331163b | 2899 | * @param status ICU error code. |
2ca993e8 | 2900 | * @stable ICU 54 |
b331163b A |
2901 | */ |
2902 | static MeasureUnit *createCubicCentimeter(UErrorCode &status); | |
2903 | ||
3d1f044b A |
2904 | #ifndef U_HIDE_DRAFT_API |
2905 | /** | |
2906 | * Returns by value, unit of volume: cubic-centimeter. | |
2907 | * Also see {@link #createCubicCentimeter()}. | |
2908 | * @draft ICU 64 | |
2909 | */ | |
2910 | static MeasureUnit getCubicCentimeter(); | |
2911 | #endif /* U_HIDE_DRAFT_API */ | |
2912 | ||
b331163b | 2913 | /** |
3d1f044b | 2914 | * Returns by pointer, unit of volume: cubic-foot. |
b331163b | 2915 | * Caller owns returned value and must free it. |
3d1f044b | 2916 | * Also see {@link #getCubicFoot()}. |
b331163b | 2917 | * @param status ICU error code. |
2ca993e8 | 2918 | * @stable ICU 54 |
b331163b A |
2919 | */ |
2920 | static MeasureUnit *createCubicFoot(UErrorCode &status); | |
2921 | ||
3d1f044b A |
2922 | #ifndef U_HIDE_DRAFT_API |
2923 | /** | |
2924 | * Returns by value, unit of volume: cubic-foot. | |
2925 | * Also see {@link #createCubicFoot()}. | |
2926 | * @draft ICU 64 | |
2927 | */ | |
2928 | static MeasureUnit getCubicFoot(); | |
2929 | #endif /* U_HIDE_DRAFT_API */ | |
2930 | ||
b331163b | 2931 | /** |
3d1f044b | 2932 | * Returns by pointer, unit of volume: cubic-inch. |
b331163b | 2933 | * Caller owns returned value and must free it. |
3d1f044b | 2934 | * Also see {@link #getCubicInch()}. |
b331163b | 2935 | * @param status ICU error code. |
2ca993e8 | 2936 | * @stable ICU 54 |
b331163b A |
2937 | */ |
2938 | static MeasureUnit *createCubicInch(UErrorCode &status); | |
2939 | ||
3d1f044b | 2940 | #ifndef U_HIDE_DRAFT_API |
b331163b | 2941 | /** |
3d1f044b A |
2942 | * Returns by value, unit of volume: cubic-inch. |
2943 | * Also see {@link #createCubicInch()}. | |
2944 | * @draft ICU 64 | |
2945 | */ | |
2946 | static MeasureUnit getCubicInch(); | |
2947 | #endif /* U_HIDE_DRAFT_API */ | |
2948 | ||
2949 | /** | |
2950 | * Returns by pointer, unit of volume: cubic-kilometer. | |
b331163b | 2951 | * Caller owns returned value and must free it. |
3d1f044b | 2952 | * Also see {@link #getCubicKilometer()}. |
b331163b A |
2953 | * @param status ICU error code. |
2954 | * @stable ICU 53 | |
2955 | */ | |
2956 | static MeasureUnit *createCubicKilometer(UErrorCode &status); | |
2957 | ||
3d1f044b A |
2958 | #ifndef U_HIDE_DRAFT_API |
2959 | /** | |
2960 | * Returns by value, unit of volume: cubic-kilometer. | |
2961 | * Also see {@link #createCubicKilometer()}. | |
2962 | * @draft ICU 64 | |
2963 | */ | |
2964 | static MeasureUnit getCubicKilometer(); | |
2965 | #endif /* U_HIDE_DRAFT_API */ | |
2966 | ||
b331163b | 2967 | /** |
3d1f044b | 2968 | * Returns by pointer, unit of volume: cubic-meter. |
b331163b | 2969 | * Caller owns returned value and must free it. |
3d1f044b | 2970 | * Also see {@link #getCubicMeter()}. |
b331163b | 2971 | * @param status ICU error code. |
2ca993e8 | 2972 | * @stable ICU 54 |
b331163b A |
2973 | */ |
2974 | static MeasureUnit *createCubicMeter(UErrorCode &status); | |
2975 | ||
3d1f044b A |
2976 | #ifndef U_HIDE_DRAFT_API |
2977 | /** | |
2978 | * Returns by value, unit of volume: cubic-meter. | |
2979 | * Also see {@link #createCubicMeter()}. | |
2980 | * @draft ICU 64 | |
2981 | */ | |
2982 | static MeasureUnit getCubicMeter(); | |
2983 | #endif /* U_HIDE_DRAFT_API */ | |
2984 | ||
b331163b | 2985 | /** |
3d1f044b | 2986 | * Returns by pointer, unit of volume: cubic-mile. |
b331163b | 2987 | * Caller owns returned value and must free it. |
3d1f044b | 2988 | * Also see {@link #getCubicMile()}. |
b331163b A |
2989 | * @param status ICU error code. |
2990 | * @stable ICU 53 | |
2991 | */ | |
2992 | static MeasureUnit *createCubicMile(UErrorCode &status); | |
2993 | ||
3d1f044b A |
2994 | #ifndef U_HIDE_DRAFT_API |
2995 | /** | |
2996 | * Returns by value, unit of volume: cubic-mile. | |
2997 | * Also see {@link #createCubicMile()}. | |
2998 | * @draft ICU 64 | |
2999 | */ | |
3000 | static MeasureUnit getCubicMile(); | |
3001 | #endif /* U_HIDE_DRAFT_API */ | |
3002 | ||
b331163b | 3003 | /** |
3d1f044b | 3004 | * Returns by pointer, unit of volume: cubic-yard. |
b331163b | 3005 | * Caller owns returned value and must free it. |
3d1f044b | 3006 | * Also see {@link #getCubicYard()}. |
b331163b | 3007 | * @param status ICU error code. |
2ca993e8 | 3008 | * @stable ICU 54 |
b331163b A |
3009 | */ |
3010 | static MeasureUnit *createCubicYard(UErrorCode &status); | |
3011 | ||
3d1f044b | 3012 | #ifndef U_HIDE_DRAFT_API |
b331163b | 3013 | /** |
3d1f044b A |
3014 | * Returns by value, unit of volume: cubic-yard. |
3015 | * Also see {@link #createCubicYard()}. | |
3016 | * @draft ICU 64 | |
3017 | */ | |
3018 | static MeasureUnit getCubicYard(); | |
3019 | #endif /* U_HIDE_DRAFT_API */ | |
3020 | ||
3021 | /** | |
3022 | * Returns by pointer, unit of volume: cup. | |
b331163b | 3023 | * Caller owns returned value and must free it. |
3d1f044b | 3024 | * Also see {@link #getCup()}. |
b331163b | 3025 | * @param status ICU error code. |
2ca993e8 | 3026 | * @stable ICU 54 |
b331163b A |
3027 | */ |
3028 | static MeasureUnit *createCup(UErrorCode &status); | |
3029 | ||
3d1f044b A |
3030 | #ifndef U_HIDE_DRAFT_API |
3031 | /** | |
3032 | * Returns by value, unit of volume: cup. | |
3033 | * Also see {@link #createCup()}. | |
3034 | * @draft ICU 64 | |
3035 | */ | |
3036 | static MeasureUnit getCup(); | |
3037 | #endif /* U_HIDE_DRAFT_API */ | |
3038 | ||
2ca993e8 | 3039 | /** |
3d1f044b | 3040 | * Returns by pointer, unit of volume: cup-metric. |
2ca993e8 | 3041 | * Caller owns returned value and must free it. |
3d1f044b | 3042 | * Also see {@link #getCupMetric()}. |
2ca993e8 | 3043 | * @param status ICU error code. |
f3c0d7a5 | 3044 | * @stable ICU 56 |
2ca993e8 A |
3045 | */ |
3046 | static MeasureUnit *createCupMetric(UErrorCode &status); | |
2ca993e8 | 3047 | |
3d1f044b A |
3048 | #ifndef U_HIDE_DRAFT_API |
3049 | /** | |
3050 | * Returns by value, unit of volume: cup-metric. | |
3051 | * Also see {@link #createCupMetric()}. | |
3052 | * @draft ICU 64 | |
3053 | */ | |
3054 | static MeasureUnit getCupMetric(); | |
3055 | #endif /* U_HIDE_DRAFT_API */ | |
3056 | ||
b331163b | 3057 | /** |
3d1f044b | 3058 | * Returns by pointer, unit of volume: deciliter. |
b331163b | 3059 | * Caller owns returned value and must free it. |
3d1f044b | 3060 | * Also see {@link #getDeciliter()}. |
b331163b | 3061 | * @param status ICU error code. |
2ca993e8 | 3062 | * @stable ICU 54 |
b331163b A |
3063 | */ |
3064 | static MeasureUnit *createDeciliter(UErrorCode &status); | |
3065 | ||
3d1f044b A |
3066 | #ifndef U_HIDE_DRAFT_API |
3067 | /** | |
3068 | * Returns by value, unit of volume: deciliter. | |
3069 | * Also see {@link #createDeciliter()}. | |
3070 | * @draft ICU 64 | |
3071 | */ | |
3072 | static MeasureUnit getDeciliter(); | |
3073 | #endif /* U_HIDE_DRAFT_API */ | |
3074 | ||
b331163b | 3075 | /** |
3d1f044b | 3076 | * Returns by pointer, unit of volume: fluid-ounce. |
b331163b | 3077 | * Caller owns returned value and must free it. |
3d1f044b | 3078 | * Also see {@link #getFluidOunce()}. |
b331163b | 3079 | * @param status ICU error code. |
2ca993e8 | 3080 | * @stable ICU 54 |
b331163b A |
3081 | */ |
3082 | static MeasureUnit *createFluidOunce(UErrorCode &status); | |
3083 | ||
3d1f044b A |
3084 | #ifndef U_HIDE_DRAFT_API |
3085 | /** | |
3086 | * Returns by value, unit of volume: fluid-ounce. | |
3087 | * Also see {@link #createFluidOunce()}. | |
3088 | * @draft ICU 64 | |
3089 | */ | |
3090 | static MeasureUnit getFluidOunce(); | |
3091 | #endif /* U_HIDE_DRAFT_API */ | |
3092 | ||
3093 | #ifndef U_HIDE_DRAFT_API | |
3094 | /** | |
3095 | * Returns by pointer, unit of volume: fluid-ounce-imperial. | |
3096 | * Caller owns returned value and must free it. | |
3097 | * Also see {@link #getFluidOunceImperial()}. | |
3098 | * @param status ICU error code. | |
3099 | * @draft ICU 64 | |
3100 | */ | |
3101 | static MeasureUnit *createFluidOunceImperial(UErrorCode &status); | |
3102 | ||
b331163b | 3103 | /** |
3d1f044b A |
3104 | * Returns by value, unit of volume: fluid-ounce-imperial. |
3105 | * Also see {@link #createFluidOunceImperial()}. | |
3106 | * @draft ICU 64 | |
3107 | */ | |
3108 | static MeasureUnit getFluidOunceImperial(); | |
3109 | #endif /* U_HIDE_DRAFT_API */ | |
3110 | ||
3111 | /** | |
3112 | * Returns by pointer, unit of volume: gallon. | |
b331163b | 3113 | * Caller owns returned value and must free it. |
3d1f044b | 3114 | * Also see {@link #getGallon()}. |
b331163b | 3115 | * @param status ICU error code. |
2ca993e8 | 3116 | * @stable ICU 54 |
b331163b A |
3117 | */ |
3118 | static MeasureUnit *createGallon(UErrorCode &status); | |
3119 | ||
3d1f044b A |
3120 | #ifndef U_HIDE_DRAFT_API |
3121 | /** | |
3122 | * Returns by value, unit of volume: gallon. | |
3123 | * Also see {@link #createGallon()}. | |
3124 | * @draft ICU 64 | |
3125 | */ | |
3126 | static MeasureUnit getGallon(); | |
3127 | #endif /* U_HIDE_DRAFT_API */ | |
3128 | ||
2ca993e8 | 3129 | /** |
3d1f044b | 3130 | * Returns by pointer, unit of volume: gallon-imperial. |
2ca993e8 | 3131 | * Caller owns returned value and must free it. |
3d1f044b | 3132 | * Also see {@link #getGallonImperial()}. |
2ca993e8 | 3133 | * @param status ICU error code. |
f3c0d7a5 | 3134 | * @stable ICU 57 |
2ca993e8 A |
3135 | */ |
3136 | static MeasureUnit *createGallonImperial(UErrorCode &status); | |
2ca993e8 | 3137 | |
3d1f044b A |
3138 | #ifndef U_HIDE_DRAFT_API |
3139 | /** | |
3140 | * Returns by value, unit of volume: gallon-imperial. | |
3141 | * Also see {@link #createGallonImperial()}. | |
3142 | * @draft ICU 64 | |
3143 | */ | |
3144 | static MeasureUnit getGallonImperial(); | |
3145 | #endif /* U_HIDE_DRAFT_API */ | |
3146 | ||
b331163b | 3147 | /** |
3d1f044b | 3148 | * Returns by pointer, unit of volume: hectoliter. |
b331163b | 3149 | * Caller owns returned value and must free it. |
3d1f044b | 3150 | * Also see {@link #getHectoliter()}. |
b331163b | 3151 | * @param status ICU error code. |
2ca993e8 | 3152 | * @stable ICU 54 |
b331163b A |
3153 | */ |
3154 | static MeasureUnit *createHectoliter(UErrorCode &status); | |
3155 | ||
3d1f044b A |
3156 | #ifndef U_HIDE_DRAFT_API |
3157 | /** | |
3158 | * Returns by value, unit of volume: hectoliter. | |
3159 | * Also see {@link #createHectoliter()}. | |
3160 | * @draft ICU 64 | |
3161 | */ | |
3162 | static MeasureUnit getHectoliter(); | |
3163 | #endif /* U_HIDE_DRAFT_API */ | |
3164 | ||
b331163b | 3165 | /** |
3d1f044b | 3166 | * Returns by pointer, unit of volume: liter. |
b331163b | 3167 | * Caller owns returned value and must free it. |
3d1f044b | 3168 | * Also see {@link #getLiter()}. |
b331163b A |
3169 | * @param status ICU error code. |
3170 | * @stable ICU 53 | |
3171 | */ | |
3172 | static MeasureUnit *createLiter(UErrorCode &status); | |
3173 | ||
3d1f044b | 3174 | #ifndef U_HIDE_DRAFT_API |
b331163b | 3175 | /** |
3d1f044b A |
3176 | * Returns by value, unit of volume: liter. |
3177 | * Also see {@link #createLiter()}. | |
3178 | * @draft ICU 64 | |
3179 | */ | |
3180 | static MeasureUnit getLiter(); | |
3181 | #endif /* U_HIDE_DRAFT_API */ | |
3182 | ||
3183 | /** | |
3184 | * Returns by pointer, unit of volume: megaliter. | |
b331163b | 3185 | * Caller owns returned value and must free it. |
3d1f044b | 3186 | * Also see {@link #getMegaliter()}. |
b331163b | 3187 | * @param status ICU error code. |
2ca993e8 | 3188 | * @stable ICU 54 |
b331163b A |
3189 | */ |
3190 | static MeasureUnit *createMegaliter(UErrorCode &status); | |
3191 | ||
3d1f044b A |
3192 | #ifndef U_HIDE_DRAFT_API |
3193 | /** | |
3194 | * Returns by value, unit of volume: megaliter. | |
3195 | * Also see {@link #createMegaliter()}. | |
3196 | * @draft ICU 64 | |
3197 | */ | |
3198 | static MeasureUnit getMegaliter(); | |
3199 | #endif /* U_HIDE_DRAFT_API */ | |
3200 | ||
b331163b | 3201 | /** |
3d1f044b | 3202 | * Returns by pointer, unit of volume: milliliter. |
b331163b | 3203 | * Caller owns returned value and must free it. |
3d1f044b | 3204 | * Also see {@link #getMilliliter()}. |
b331163b | 3205 | * @param status ICU error code. |
2ca993e8 | 3206 | * @stable ICU 54 |
b331163b A |
3207 | */ |
3208 | static MeasureUnit *createMilliliter(UErrorCode &status); | |
3209 | ||
3d1f044b A |
3210 | #ifndef U_HIDE_DRAFT_API |
3211 | /** | |
3212 | * Returns by value, unit of volume: milliliter. | |
3213 | * Also see {@link #createMilliliter()}. | |
3214 | * @draft ICU 64 | |
3215 | */ | |
3216 | static MeasureUnit getMilliliter(); | |
3217 | #endif /* U_HIDE_DRAFT_API */ | |
3218 | ||
b331163b | 3219 | /** |
3d1f044b | 3220 | * Returns by pointer, unit of volume: pint. |
b331163b | 3221 | * Caller owns returned value and must free it. |
3d1f044b | 3222 | * Also see {@link #getPint()}. |
b331163b | 3223 | * @param status ICU error code. |
2ca993e8 | 3224 | * @stable ICU 54 |
b331163b A |
3225 | */ |
3226 | static MeasureUnit *createPint(UErrorCode &status); | |
3227 | ||
3d1f044b A |
3228 | #ifndef U_HIDE_DRAFT_API |
3229 | /** | |
3230 | * Returns by value, unit of volume: pint. | |
3231 | * Also see {@link #createPint()}. | |
3232 | * @draft ICU 64 | |
3233 | */ | |
3234 | static MeasureUnit getPint(); | |
3235 | #endif /* U_HIDE_DRAFT_API */ | |
3236 | ||
2ca993e8 | 3237 | /** |
3d1f044b | 3238 | * Returns by pointer, unit of volume: pint-metric. |
2ca993e8 | 3239 | * Caller owns returned value and must free it. |
3d1f044b | 3240 | * Also see {@link #getPintMetric()}. |
2ca993e8 | 3241 | * @param status ICU error code. |
f3c0d7a5 | 3242 | * @stable ICU 56 |
2ca993e8 A |
3243 | */ |
3244 | static MeasureUnit *createPintMetric(UErrorCode &status); | |
2ca993e8 | 3245 | |
3d1f044b | 3246 | #ifndef U_HIDE_DRAFT_API |
b331163b | 3247 | /** |
3d1f044b A |
3248 | * Returns by value, unit of volume: pint-metric. |
3249 | * Also see {@link #createPintMetric()}. | |
3250 | * @draft ICU 64 | |
3251 | */ | |
3252 | static MeasureUnit getPintMetric(); | |
3253 | #endif /* U_HIDE_DRAFT_API */ | |
3254 | ||
3255 | /** | |
3256 | * Returns by pointer, unit of volume: quart. | |
b331163b | 3257 | * Caller owns returned value and must free it. |
3d1f044b | 3258 | * Also see {@link #getQuart()}. |
b331163b | 3259 | * @param status ICU error code. |
2ca993e8 | 3260 | * @stable ICU 54 |
b331163b A |
3261 | */ |
3262 | static MeasureUnit *createQuart(UErrorCode &status); | |
3263 | ||
3d1f044b A |
3264 | #ifndef U_HIDE_DRAFT_API |
3265 | /** | |
3266 | * Returns by value, unit of volume: quart. | |
3267 | * Also see {@link #createQuart()}. | |
3268 | * @draft ICU 64 | |
3269 | */ | |
3270 | static MeasureUnit getQuart(); | |
3271 | #endif /* U_HIDE_DRAFT_API */ | |
3272 | ||
b331163b | 3273 | /** |
3d1f044b | 3274 | * Returns by pointer, unit of volume: tablespoon. |
b331163b | 3275 | * Caller owns returned value and must free it. |
3d1f044b | 3276 | * Also see {@link #getTablespoon()}. |
b331163b | 3277 | * @param status ICU error code. |
2ca993e8 | 3278 | * @stable ICU 54 |
b331163b A |
3279 | */ |
3280 | static MeasureUnit *createTablespoon(UErrorCode &status); | |
3281 | ||
3d1f044b A |
3282 | #ifndef U_HIDE_DRAFT_API |
3283 | /** | |
3284 | * Returns by value, unit of volume: tablespoon. | |
3285 | * Also see {@link #createTablespoon()}. | |
3286 | * @draft ICU 64 | |
3287 | */ | |
3288 | static MeasureUnit getTablespoon(); | |
3289 | #endif /* U_HIDE_DRAFT_API */ | |
3290 | ||
b331163b | 3291 | /** |
3d1f044b | 3292 | * Returns by pointer, unit of volume: teaspoon. |
b331163b | 3293 | * Caller owns returned value and must free it. |
3d1f044b | 3294 | * Also see {@link #getTeaspoon()}. |
b331163b | 3295 | * @param status ICU error code. |
2ca993e8 | 3296 | * @stable ICU 54 |
b331163b A |
3297 | */ |
3298 | static MeasureUnit *createTeaspoon(UErrorCode &status); | |
3299 | ||
3d1f044b A |
3300 | #ifndef U_HIDE_DRAFT_API |
3301 | /** | |
3302 | * Returns by value, unit of volume: teaspoon. | |
3303 | * Also see {@link #createTeaspoon()}. | |
3304 | * @draft ICU 64 | |
3305 | */ | |
3306 | static MeasureUnit getTeaspoon(); | |
3307 | #endif /* U_HIDE_DRAFT_API */ | |
3308 | ||
b331163b A |
3309 | |
3310 | // End generated createXXX methods | |
374ca955 A |
3311 | |
3312 | protected: | |
57a6839d A |
3313 | |
3314 | #ifndef U_HIDE_INTERNAL_API | |
374ca955 | 3315 | /** |
57a6839d A |
3316 | * For ICU use only. |
3317 | * @internal | |
3318 | */ | |
3319 | void initTime(const char *timeId); | |
3320 | ||
3321 | /** | |
3322 | * For ICU use only. | |
3323 | * @internal | |
374ca955 | 3324 | */ |
57a6839d A |
3325 | void initCurrency(const char *isoCurrency); |
3326 | ||
0f5d89e8 A |
3327 | /** |
3328 | * For ICU use only. | |
3329 | * @internal | |
3330 | */ | |
3331 | void initNoUnit(const char *subtype); | |
3332 | ||
b331163b | 3333 | #endif /* U_HIDE_INTERNAL_API */ |
57a6839d A |
3334 | |
3335 | private: | |
3336 | int32_t fTypeId; | |
3337 | int32_t fSubTypeId; | |
3338 | char fCurrency[4]; | |
3339 | ||
3340 | MeasureUnit(int32_t typeId, int32_t subTypeId) : fTypeId(typeId), fSubTypeId(subTypeId) { | |
3341 | fCurrency[0] = 0; | |
3342 | } | |
3343 | void setTo(int32_t typeId, int32_t subTypeId); | |
3344 | int32_t getOffset() const; | |
3345 | static MeasureUnit *create(int typeId, int subTypeId, UErrorCode &status); | |
374ca955 A |
3346 | }; |
3347 | ||
3348 | U_NAMESPACE_END | |
3349 | ||
57a6839d | 3350 | #endif // !UNCONFIG_NO_FORMATTING |
340931cb A |
3351 | |
3352 | #endif /* U_SHOW_CPLUSPLUS_API */ | |
3353 | ||
374ca955 | 3354 | #endif // __MEASUREUNIT_H__ |