Lines Matching refs:format
35 #include "unicode/format.h"
57 * NumberFormat helps you to format and parse numbers for any locale.
60 * decimal digits used, or whether the number format is even decimal.
62 * To format a number for the current Locale, use one of the static
70 * nf->format(myNumber, myString);
78 * the format and use it multiple times so that the system doesn't
90 * nf->format(a[i], myString);
96 * To format a number for a different Locale, specify it in the
111 * Use createInstance to get the normal number format for that country.
113 * to get the currency number format for that country. Use getPercent
114 * to get a format for displaying percentages. With this format, a
120 * use createInstance(...kNumberStyle...) to get the normal number format,
121 * createInstance(...kPercentStyle...) to get a format for displaying
123 * createInstance(...kScientificStyle...) to get a format for displaying
125 * createInstance(...kCurrencyStyle...) to get the currency number format,
127 * createInstance(...kIsoCurrencyStyle...) to get the currency number format,
129 * createInstance(...kPluralCurrencyStyle...) to get the currency number format,
130 * in which the currency is represented by its full name in plural format,
135 * format or parsing, or want to give your users more control, you can
141 * You can also use forms of the parse and format methods with
150 * can pass the FieldPosition in your format call, with field =
169 class U_I18N_API NumberFormat : public Format {
177 * support identification of all number format fields, not just those
227 * Return true if the given Format objects are semantically equal.
229 * @return true if the given Format objects are semantically equal.
232 virtual UBool operator==(const Format& other) const;
235 using Format::format;
238 * Format an object to produce a string. This method handles
243 * @param obj The object to format.
252 virtual UnicodeString& format(const Formattable& obj,
258 * Format an object to produce a string. This method handles
263 * @param obj The object to format.
267 * of fields generated by this format call. Can be
273 virtual UnicodeString& format(const Formattable& obj,
291 * See Format::parseObject() for more.
311 * Format a double number. These methods call the NumberFormat
312 * pure virtual format() methods with the default FieldPosition.
320 UnicodeString& format( double number,
324 * Format a long number. These methods call the NumberFormat
325 * pure virtual format() methods with the default FieldPosition.
333 UnicodeString& format( int32_t number,
337 * Format an int64 number. These methods call the NumberFormat
338 * pure virtual format() methods with the default FieldPosition.
346 UnicodeString& format( int64_t number,
350 * Format a double number. Concrete subclasses must implement
361 virtual UnicodeString& format(double number,
365 * Format a double number. By default, the parent function simply
378 virtual UnicodeString& format(double number,
383 * Format a double number. Subclasses must implement
390 * of fields generated by this format call.
396 virtual UnicodeString& format(double number,
401 * Format a long number. Concrete subclasses must implement
412 virtual UnicodeString& format(int32_t number,
417 * Format a long number. Concrete subclasses may override
429 virtual UnicodeString& format(int32_t number,
435 * Format an int32 number. Subclasses must implement
442 * of fields generated by this format call.
448 virtual UnicodeString& format(int32_t number,
453 * Format an int64 number. (Not abstract to retain compatibility
455 * method as it just delegates to format(int32_t number...);
465 virtual UnicodeString& format(int64_t number,
470 * Format an int64 number. (Not abstract to retain compatibility
472 * method as it just delegates to format(int32_t number...);
482 virtual UnicodeString& format(int64_t number,
487 * Format an int64 number. Subclasses must implement
494 * of fields generated by this format call.
500 virtual UnicodeString& format(int64_t number,
506 * Format a decimal number. Subclasses must implement
515 * of fields generated by this format call.
521 virtual UnicodeString& format(const StringPiece &number,
527 * Format a decimal number.
534 * @param number The number, a DigitList format Decimal Floating Point.
538 * of fields generated by this format call.
543 virtual UnicodeString& format(const DigitList &number,
549 * Format a decimal number.
556 * @param number The number, a DigitList format Decimal Floating Point.
565 virtual UnicodeString& format(const DigitList &number,
573 * Redeclared Format method.
582 UnicodeString& format(const Formattable& obj,
631 * This method will fail if this format is not a currency format,
649 * Return true if this format will parse numbers as integers
653 * the exact format accepted by the parse operation is locale
655 * @return true if this format will parse numbers as integers
663 * @param value set True, this format will parse numbers as integers
690 * Returns the default number format for the current default
691 * locale. The default format is one of the styles provided by
700 * Returns the default number format for the specified locale.
701 * The default format is one of the styles provided by the other
711 * Creates the specified decimal format style of the desired locale.
723 * Returns a currency format for the current default locale.
729 * Returns a currency format for the specified locale.
737 * Returns a percentage format for the current default locale.
743 * Returns a percentage format for the specified locale.
751 * Returns a scientific format for the current default locale.
757 * Returns a scientific format for the specified locale.
802 * Returns true if grouping is used in this format. For example,
813 * Set whether or not grouping will be used in this format.
814 * @param newValue True, grouping will be used in this format.
912 * amounts. This takes effect immediately, if this format is a
913 * currency format. If this format is not a currency format, then
915 * currency format.
990 * Creates the specified number format style of the desired locale.
1006 * Creates the specified decimal format style of the desired locale.
1066 * Return a number format of the appropriate type. If the locale
1131 NumberFormat::format(const Formattable& obj,
1134 return Format::format(obj, appendTo, status);