*/
#if !UCONFIG_NO_FORMATTING
+#ifndef U_HIDE_DEPRECATED_API
#include "unicode/fieldpos.h"
#include "unicode/format.h"
* <p><em>User subclasses are not supported.</em> While clients may write
* subclasses, such code will not necessarily work and will not be
* guaranteed to work stably from release to release.
+ *
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
class U_I18N_API ChoiceFormat: public NumberFormat {
public:
* @param pattern Pattern used to construct object.
* @param status Output param to receive success code. If the
* pattern cannot be parsed, set to failure code.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
ChoiceFormat(const UnicodeString& pattern,
UErrorCode& status);
* @param limits Array of limit values.
* @param formats Array of formats.
* @param count Size of 'limits' and 'formats' arrays.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
ChoiceFormat(const double* limits,
const UnicodeString* formats,
* If TRUE, then the limit number belongs to the previous range it.
* @param formats Array of formats
* @param count Size of 'limits', 'closures', and 'formats' arrays
- * @stable ICU 2.4
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
ChoiceFormat(const double* limits,
const UBool* closures,
* Copy constructor.
*
* @param that ChoiceFormat object to be copied from
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
ChoiceFormat(const ChoiceFormat& that);
* Assignment operator.
*
* @param that ChoiceFormat object to be copied
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
const ChoiceFormat& operator=(const ChoiceFormat& that);
/**
* Destructor.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual ~ChoiceFormat();
* result and must delete it when done.
*
* @return a copy of this object
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual Format* clone(void) const;
*
* @param other ChoiceFormat object to be compared
* @return true if other is the same as this.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual UBool operator==(const Format& other) const;
* @param status Output param set to success/failure code on
* exit. If the pattern is invalid, this will be
* set to a failure result.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual void applyPattern(const UnicodeString& pattern,
UErrorCode& status);
* @param status Output param set to success/failure code on
* exit. If the pattern is invalid, this will be
* set to a failure result.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual void applyPattern(const UnicodeString& pattern,
UParseError& parseError,
* @param pattern Output param which will receive the pattern
* Previous contents are deleted.
* @return A reference to 'pattern'
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual UnicodeString& toPattern(UnicodeString &pattern) const;
* <= X < limit[i+1].
* @param formatsToCopy The format strings you want to use for each limit.
* @param count The size of the above arrays.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual void setChoices(const double* limitsToCopy,
const UnicodeString* formatsToCopy,
* @param closures Array of limit booleans
* @param formats Array of format string
* @param count The size of the above arrays
- * @stable ICU 2.4
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual void setChoices(const double* limits,
const UBool* closures,
* @param pos On input: an alignment field, if desired.
* On output: the offsets of the alignment field.
* @return Reference to 'appendTo' parameter.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual UnicodeString& format(double number,
UnicodeString& appendTo,
* @param pos On input: an alignment field, if desired.
* On output: the offsets of the alignment field.
* @return Reference to 'appendTo' parameter.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual UnicodeString& format(int32_t number,
UnicodeString& appendTo,
* @param pos On input: an alignment field, if desired.
* On output: the offsets of the alignment field.
* @return Reference to 'appendTo' parameter.
- * @stable ICU 2.8
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual UnicodeString& format(int64_t number,
UnicodeString& appendTo,
* @param success Output param set to success/failure code on
* exit.
* @return Reference to 'appendTo' parameter.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual UnicodeString& format(const Formattable* objs,
int32_t cnt,
* @param status Output param set to success/failure code on
* exit.
* @return Reference to 'appendTo' parameter.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo,
* @param status Output param set to success/failure code on
* exit.
* @return Reference to 'appendTo' parameter.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
UnicodeString& format(const Formattable& obj,
UnicodeString& appendTo,
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @return Reference to 'appendTo' parameter.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
UnicodeString& format( double number,
UnicodeString& appendTo) const;
* @param appendTo Output parameter to receive result.
* Result is appended to existing contents.
* @return Reference to 'appendTo' parameter.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
UnicodeString& format( int32_t number,
UnicodeString& appendTo) const;
* @param parsePosition The position to start parsing at on input.
* On output, moved to after the last successfully
* parse character. On parse failure, does not change.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual void parse(const UnicodeString& text,
Formattable& result,
* @param result Formattable to be set to the parse result.
* If parse fails, return contents are undefined.
* @param status Output param with the formatted string.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual void parse(const UnicodeString& text,
Formattable& result,
* @return The class ID for this object. All objects of a
* given class have the same class ID. Objects of
* other classes have different class IDs.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
virtual UClassID getDynamicClassID(void) const;
* . Derived::getStaticClassID()) ...
* </pre>
* @return The class ID for all objects of this class.
- * @stable ICU 2.0
+ * @deprecated ICU 49 Use MessageFormat instead, with plural and select arguments.
*/
static UClassID U_EXPORT2 getStaticClassID(void);
* of error if an error is encountered.
* @param status Output param to receive success code. If the
* pattern cannot be parsed, set to failure code.
- * @stable ICU 2.0
*/
ChoiceFormat(const UnicodeString& newPattern,
UParseError& parseError,
}
U_NAMESPACE_END
+#endif // U_HIDE_DEPRECATED_API
#endif /* #if !UCONFIG_NO_FORMATTING */
-#endif // _CHOICFMT
+#endif // CHOICFMT_H
//eof