Sophie

Sophie

distrib > Mandriva > 2008.1 > x86_64 > by-pkgid > 280da2a01a3d16776505ea3f476de84f > files > 45

icu-doc-3.8.1-2mdv2008.1.x86_64.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>ICU 3.8: ChoiceFormat Class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.1 -->
<div class="tabs">
  <ul>
    <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
    <li><a href="modules.html"><span>Modules</span></a></li>
    <li id="current"><a href="classes.html"><span>Data&nbsp;Structures</span></a></li>
    <li><a href="files.html"><span>Files</span></a></li>
    <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
    <li>
      <form action="search.php" method="get">
        <table cellspacing="0" cellpadding="0" border="0">
          <tr>
            <td><label>&nbsp;<u>S</u>earch&nbsp;for&nbsp;</label></td>
            <td><input type="text" name="query" value="" size="20" accesskey="s"/></td>
          </tr>
        </table>
      </form>
    </li>
  </ul></div>
<div class="tabs">
  <ul>
    <li><a href="classes.html"><span>Alphabetical&nbsp;List</span></a></li>
    <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
    <li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
    <li><a href="functions.html"><span>Data&nbsp;Fields</span></a></li>
  </ul></div>
<h1>ChoiceFormat Class Reference</h1><!-- doxytag: class="ChoiceFormat" --><!-- doxytag: inherits="NumberFormat" --><a class="el" href="classChoiceFormat.html">ChoiceFormat</a> converts between ranges of numeric values and string names for those ranges.  
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="choicfmt_8h-source.html">choicfmt.h</a>&gt;</code>
<p>
<p>Inheritance diagram for ChoiceFormat:
<p><center><img src="classChoiceFormat.png" usemap="#ChoiceFormat_map" border="0" alt=""></center>
<map name="ChoiceFormat_map">
<area href="classNumberFormat.html" alt="NumberFormat" shape="rect" coords="0,168,95,192">
<area href="classFormat.html" alt="Format" shape="rect" coords="0,112,95,136">
<area href="classUObject.html" alt="UObject" shape="rect" coords="0,56,95,80">
<area href="classUMemory.html" alt="UMemory" shape="rect" coords="0,0,95,24">
</map>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#9551b876e173743f214d1530368ee92d">ChoiceFormat</a> (const <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;pattern, <a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;status)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Construct a new <a class="el" href="classChoiceFormat.html">ChoiceFormat</a> with the limits and the corresponding formats based on the pattern.  <a href="#9551b876e173743f214d1530368ee92d"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#5f097ff199910610ab5a5eb113e034e8">ChoiceFormat</a> (const double *limits, const <a class="el" href="classUnicodeString.html">UnicodeString</a> *formats, <a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> count)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Construct a new <a class="el" href="classChoiceFormat.html">ChoiceFormat</a> with the given limits and formats.  <a href="#5f097ff199910610ab5a5eb113e034e8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#491cc4d24cbd4c42acebb158b1e04204">ChoiceFormat</a> (const double *limits, const <a class="el" href="umachine_8h.html#349ef00011f20ccd1d3b424445681aa5">UBool</a> *closures, const <a class="el" href="classUnicodeString.html">UnicodeString</a> *formats, <a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> count)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Construct a new <a class="el" href="classChoiceFormat.html">ChoiceFormat</a> with the given limits and formats.  <a href="#491cc4d24cbd4c42acebb158b1e04204"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#aac82d203aea4854d148eabe422a8b17">ChoiceFormat</a> (const <a class="el" href="classChoiceFormat.html">ChoiceFormat</a> &amp;that)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Copy constructor.  <a href="#aac82d203aea4854d148eabe422a8b17"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">const <a class="el" href="classChoiceFormat.html">ChoiceFormat</a> &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#2873dacc65a6fd80c8111711a6f0c3b4">operator=</a> (const <a class="el" href="classChoiceFormat.html">ChoiceFormat</a> &amp;that)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Assignment operator.  <a href="#2873dacc65a6fd80c8111711a6f0c3b4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#13b14e531d655819e8f3ab2c10bf9cb5">~ChoiceFormat</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Destructor.  <a href="#13b14e531d655819e8f3ab2c10bf9cb5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classFormat.html">Format</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#3ebd2e04337baee2dbb8c7629592714d">clone</a> (void) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Clone this <a class="el" href="classFormat.html">Format</a> object polymorphically.  <a href="#3ebd2e04337baee2dbb8c7629592714d"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="umachine_8h.html#349ef00011f20ccd1d3b424445681aa5">UBool</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#68b2c94926681294a2fe0d1c7cf52975">operator==</a> (const <a class="el" href="classFormat.html">Format</a> &amp;other) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return true if the given <a class="el" href="classFormat.html">Format</a> objects are semantically equal.  <a href="#68b2c94926681294a2fe0d1c7cf52975"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#9e558988f447da3af36ef7fc8245fb55">applyPattern</a> (const <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;pattern, <a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;status)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sets the pattern.  <a href="#9e558988f447da3af36ef7fc8245fb55"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#01a7bc685dacb242a2cc12f502a88546">applyPattern</a> (const <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;pattern, <a class="el" href="structUParseError.html">UParseError</a> &amp;parseError, <a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;status)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sets the pattern.  <a href="#01a7bc685dacb242a2cc12f502a88546"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#46374a45e8f9be0760de9984f93197aa">toPattern</a> (<a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;pattern) const</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Gets the pattern.  <a href="#46374a45e8f9be0760de9984f93197aa"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#5b737cf15cc825a52b7ef14b77a5b2b2">setChoices</a> (const double *limitsToCopy, const <a class="el" href="classUnicodeString.html">UnicodeString</a> *formatsToCopy, <a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> count)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the choices to be used in formatting.  <a href="#5b737cf15cc825a52b7ef14b77a5b2b2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#7a9bfd3b21d29c46ffce3329b2d96668">setChoices</a> (const double *limits, const <a class="el" href="umachine_8h.html#349ef00011f20ccd1d3b424445681aa5">UBool</a> *closures, const <a class="el" href="classUnicodeString.html">UnicodeString</a> *formats, <a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> count)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the choices to be used in formatting.  <a href="#7a9bfd3b21d29c46ffce3329b2d96668"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual const double *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#78f83ea324ffe884a00eb700ae550cc2">getLimits</a> (<a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> &amp;count) const</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the limits passed in the constructor.  <a href="#78f83ea324ffe884a00eb700ae550cc2"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual const <a class="el" href="umachine_8h.html#349ef00011f20ccd1d3b424445681aa5">UBool</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#247a623070c20dab1b7816b70fb063a3">getClosures</a> (<a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> &amp;count) const</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the limit booleans passed in the constructor.  <a href="#247a623070c20dab1b7816b70fb063a3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual const <a class="el" href="classUnicodeString.html">UnicodeString</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#43d283a6a28349e8acb2021a93754d6d">getFormats</a> (<a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> &amp;count) const</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the formats passed in the constructor.  <a href="#43d283a6a28349e8acb2021a93754d6d"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#3488103b67c452ace7cac7f6da452e72">format</a> (double number, <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;appendTo, <a class="el" href="classFieldPosition.html">FieldPosition</a> &amp;pos) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="classFormat.html">Format</a> a double or long number using this object's choices.  <a href="#3488103b67c452ace7cac7f6da452e72"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#4c31ee3278dc0afb02e83127d4677161">format</a> (<a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> number, <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;appendTo, <a class="el" href="classFieldPosition.html">FieldPosition</a> &amp;pos) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="classFormat.html">Format</a> a int_32t number using this object's choices.  <a href="#4c31ee3278dc0afb02e83127d4677161"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#066409675f3c1ec30237668f7e3a80f0">format</a> (<a class="el" href="pwin32_8h.html#dec1df1b8b51cb32b77e5b86fff46471">int64_t</a> number, <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;appendTo, <a class="el" href="classFieldPosition.html">FieldPosition</a> &amp;pos) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="classFormat.html">Format</a> an int64_t number using this object's choices.  <a href="#066409675f3c1ec30237668f7e3a80f0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#fd1964f35f534b3dc9aff6e13e37e6e1">format</a> (const <a class="el" href="classFormattable.html">Formattable</a> *objs, <a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> cnt, <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;appendTo, <a class="el" href="classFieldPosition.html">FieldPosition</a> &amp;pos, <a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;success) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="classFormat.html">Format</a> an array of objects using this object's choices.  <a href="#fd1964f35f534b3dc9aff6e13e37e6e1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#27f27c3d881d63998dd49f65b838a396">format</a> (const <a class="el" href="classFormattable.html">Formattable</a> &amp;obj, <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;appendTo, <a class="el" href="classFieldPosition.html">FieldPosition</a> &amp;pos, <a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;status) const</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight"><a class="el" href="classFormat.html">Format</a> an object using this object's choices.  <a href="#27f27c3d881d63998dd49f65b838a396"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#1df3b8b4b32453583e6cef2aa74c5d97">format</a> (const <a class="el" href="classFormattable.html">Formattable</a> &amp;obj, <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;appendTo, <a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;status) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Redeclared <a class="el" href="classNumberFormat.html">NumberFormat</a> method.  <a href="#1df3b8b4b32453583e6cef2aa74c5d97"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#0acf5d497c09ac281b23cd77010b5eb7">format</a> (double number, <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;appendTo) const</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Redeclared <a class="el" href="classNumberFormat.html">NumberFormat</a> method.  <a href="#0acf5d497c09ac281b23cd77010b5eb7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#917173c9f9f2f0d9e5f1de1dc09b7516">format</a> (<a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> number, <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;appendTo) const</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Redeclared <a class="el" href="classNumberFormat.html">NumberFormat</a> method.  <a href="#917173c9f9f2f0d9e5f1de1dc09b7516"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#f39ef720dd6a46678563da4f4f185bdd">parse</a> (const <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;text, <a class="el" href="classFormattable.html">Formattable</a> &amp;result, <a class="el" href="classParsePosition.html">ParsePosition</a> &amp;parsePosition) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return a long if possible (e.g.  <a href="#f39ef720dd6a46678563da4f4f185bdd"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#a1d8199f4ac3743ffb19f9deec3648f9">parse</a> (const <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;text, <a class="el" href="classFormattable.html">Formattable</a> &amp;result, <a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;status) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return a long if possible (e.g.  <a href="#a1d8199f4ac3743ffb19f9deec3648f9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="utypes_8h.html#22af10545208a455a6e884008df48e9f">UClassID</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#3bb9d296446885cca90a38e477ef5527">getDynamicClassID</a> (void) const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Returns a unique class ID POLYMORPHICALLY.  <a href="#3bb9d296446885cca90a38e477ef5527"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Static Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">static <a class="el" href="utypes_8h.html#22af10545208a455a6e884008df48e9f">UClassID</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#daeccf67d5eac282b6b3c4ccf020e9b5">getStaticClassID</a> (void)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the class ID for this class.  <a href="#daeccf67d5eac282b6b3c4ccf020e9b5"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Friends</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="878637013842f94d9e8f7eb5ec0411b2"></a><!-- doxytag: member="ChoiceFormat::MessageFormat" ref="878637013842f94d9e8f7eb5ec0411b2" args="" -->
class&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classChoiceFormat.html#878637013842f94d9e8f7eb5ec0411b2">MessageFormat</a></td></tr>

</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
<a class="el" href="classChoiceFormat.html">ChoiceFormat</a> converts between ranges of numeric values and string names for those ranges. 
<p>
A <code><a class="el" href="classChoiceFormat.html">ChoiceFormat</a></code> splits the real number line <code>-Inf</code> to <code>+Inf</code> into two or more contiguous ranges. Each range is mapped to a string. <code><a class="el" href="classChoiceFormat.html">ChoiceFormat</a></code> is generally used in a <code><a class="el" href="classMessageFormat.html">MessageFormat</a></code> for displaying grammatically correct plurals such as "There are 2 files."<p>
There are two methods of defining a <code><a class="el" href="classChoiceFormat.html">ChoiceFormat</a></code>; both are equivalent. The first is by using a string pattern. This is the preferred method in most cases. The second method is through direct specification of the arrays that make up the <code><a class="el" href="classChoiceFormat.html">ChoiceFormat</a></code>.<p>
<b>Patterns</b><p>
In most cases, the preferred way to define a <code><a class="el" href="classChoiceFormat.html">ChoiceFormat</a></code> is with a pattern. Here is an example of a <code><a class="el" href="classChoiceFormat.html">ChoiceFormat</a></code> pattern:<p>
 <pre>    0&#x2264;are no files|1&#x2264;is one file|1&lt;are many files</pre><p>
or equivalently,<p>
 <pre>    0#are no files|1#is one file|1&lt;are many files</pre><p>
The pattern consists of a number or <em>range specifiers</em> separated by vertical bars '|' (U+007C). There is no vertical bar after the last range. Each range specifier is of the form:<p>
 <blockquote><em>Number Separator String</em></blockquote><p>
<em>Number</em> is a floating point number that can be parsed by a default <code><a class="el" href="classNumberFormat.html">NumberFormat</a></code> for the US locale. It gives the lower limit of this range. The lower limit is either inclusive or exclusive, depending on the <em>separator</em>. The upper limit is given by the lower limit of the next range. The Unicode infinity sign  &#x221E  (U+221E) is recognized for positive infinity. It may be preceded by '-' (U+002D) to indicate negative infinity.<p>
<em>String</em> is the format string for this range, with special characters enclosed in single quotes (<code>'The # sign'</code>). Single quotes themselves are indicated by two single quotes in a row (<code>'o''clock'</code>).<p>
<em>Separator</em> is one of the following single characters:<p>
<ul>
<li>
 '&#x2264;'  (U+2264) or '#' (U+0023) indicates that the lower limit given by <em>Number</em> is inclusive. (The two characters are equivalent to <a class="el" href="classChoiceFormat.html">ChoiceFormat</a>.) This means that the limit value <em>Number</em> belongs to this range. Another way of saying this is that the corresponding closure is <code>FALSE</code>.<p>
</li>
<li>
'&lt;' (U+003C) indicates that the lower limit given by <em>Number</em> is exclusive. This means that the value <em>Number</em> belongs to the prior range. Another way of saying this is that the corresponding closure is <code>TRUE</code>. </li>
</ul>
<p>
See below for more information about closures.<p>
<b>Arrays</b><p>
A <code><a class="el" href="classChoiceFormat.html">ChoiceFormat</a></code> defining <code>n</code> intervals (<code>n</code> &gt;= 2) is specified by three arrays of <code>n</code> items:<p>
<ul>
<li>
<code>double limits[]</code> gives the start of each interval. This must be a non-decreasing list of values, none of which may be <code>NaN</code>. </li>
<li>
<code>UBool closures[]</code> determines whether each limit value is contained in the interval below it or in the interval above it. If <code>closures[i]</code> is <code>FALSE</code>, then <code>limits[i]</code> is a member of interval <code>i</code>. Otherwise it is a member of interval <code>i+1</code>. If no closures array is specified, this is equivalent to having all closures be <code>FALSE</code>. Closures allow one to specify half-open, open, or closed intervals. </li>
<li>
<code><a class="el" href="classUnicodeString.html">UnicodeString</a> formats[]</code> gives the string label associated with each interval. </li>
</ul>
<p>
<b>Formatting and Parsing</b><p>
During formatting, a number is converted to a string. <code><a class="el" href="classChoiceFormat.html">ChoiceFormat</a></code> accomplishes this by mapping the number to an interval using the following rule. Given a number <code>X</code> and and index value <code>j</code> in the range <code>0..n-1</code>, where <code>n</code> is the number of ranges:<p>
 <blockquote><code>X</code> matches <code>j</code> if and only if <code>limit[j] &lt;= X &lt; limit[j+1]</code>  </blockquote><p>
(This assumes that all closures are <code>FALSE</code>. If some closures are <code>TRUE</code> then the relations must be changed to <code>&lt;=</code> or <code>&lt;</code> as appropriate.) If there is no match, then either the first or last index is used, depending on whether the number is too low or too high. Once a number is mapped to an interval <code>j</code>, the string <code>formats[j]</code> is output.<p>
During parsing, a string is converted to a number. <code><a class="el" href="classChoiceFormat.html">ChoiceFormat</a></code> finds the element <code>formats[j]</code> equal to the string, and returns <code>limits[j]</code> as the parsed value.<p>
<b>Notes</b><p>
The first limit value does not define a range boundary. For example, in the pattern  &quot;<code>1.0#a|2.0#b</code>&quot;, the intervals are [-Inf, 2.0) and [2.0, +Inf]. It appears that the first interval should be [1.0, 2.0). However, since all values that are too small are mapped to range zero, the first interval is effectively [-Inf, 2.0). However, the first limit value <em>is</em> used during formatting. In this example, <code>parse("a")</code> returns 1.0.<p>
There are no gaps between intervals and the entire number line is covered. A <code><a class="el" href="classChoiceFormat.html">ChoiceFormat</a></code> maps <em>all</em> possible double values to a finite set of intervals.<p>
The non-number <code>NaN</code> is mapped to interval zero during formatting.<p>
<b>Examples</b><p>
Here is an example of two arrays that map the number <code>1..7</code> to the English day of the week abbreviations <code>Sun..Sat</code>. No closures array is given; this is the same as specifying all closures to be <code>FALSE</code>.<p>
<pre>    {1,2,3,4,5,6,7},
     {"Sun","Mon","Tue","Wed","Thur","Fri","Sat"}</pre><p>
Here is an example that maps the ranges [-Inf, 1), [1, 1], and (1, +Inf] to three strings. That is, the number line is split into three ranges: x &lt; 1.0, x = 1.0, and x &gt; 1.0.<p>
<pre>    {0, 1, 1},
     {FALSE, FALSE, TRUE},
     {"no files", "one file", "many files"}</pre><p>
Here is a simple example that shows formatting and parsing: <p>
<div class="fragment"><pre class="fragment"><span class="preprocessor">   #include &lt;<a class="code" href="choicfmt_8h.html">unicode/choicfmt.h</a>&gt;</span>
<span class="preprocessor">   #include &lt;<a class="code" href="unistr_8h.html">unicode/unistr.h</a>&gt;</span>
<span class="preprocessor">   #include &lt;iostream.h&gt;</span>
   
   <span class="keywordtype">int</span> main(<span class="keywordtype">int</span> argc, <span class="keywordtype">char</span> *argv[]) {
       <span class="keywordtype">double</span> limits[] = {1,2,3,4,5,6,7};
       <a class="code" href="classUnicodeString.html">UnicodeString</a> monthNames[] = {
           <span class="stringliteral">"Sun"</span>,<span class="stringliteral">"Mon"</span>,<span class="stringliteral">"Tue"</span>,<span class="stringliteral">"Wed"</span>,<span class="stringliteral">"Thu"</span>,<span class="stringliteral">"Fri"</span>,<span class="stringliteral">"Sat"</span>};
       <a class="code" href="classChoiceFormat.html">ChoiceFormat</a> fmt(limits, monthNames, 7);
       <a class="code" href="classUnicodeString.html">UnicodeString</a> str;
       <span class="keywordtype">char</span> buf[256];
       <span class="keywordflow">for</span> (<span class="keywordtype">double</span> x = 1.0; x &lt;= 8.0; x += 1.0) {
           fmt.format(x, str);
           str.<a class="code" href="classUnicodeString.html#1b1b2c3fee190473eecafd617d6a3c61">extract</a>(0, str.<a class="code" href="classUnicodeString.html#c4cf80391a0e523c27aacaba796aede6">length</a>(), buf, 256, <span class="stringliteral">""</span>);
           str.<a class="code" href="classUnicodeString.html#d8fe3cabef409468a11b77111de45ebc">truncate</a>(0);
           cout &lt;&lt; x &lt;&lt; <span class="stringliteral">" -&gt; "</span>
                &lt;&lt; buf &lt;&lt; endl;
       }
       cout &lt;&lt; endl;
       <span class="keywordflow">return</span> 0;
   }
</pre></div><p>
Here is a more complex example using a <code><a class="el" href="classChoiceFormat.html">ChoiceFormat</a></code> constructed from a pattern together with a <code><a class="el" href="classMessageFormat.html">MessageFormat</a></code>.<p>
<div class="fragment"><pre class="fragment"><span class="preprocessor">   #include &lt;<a class="code" href="choicfmt_8h.html">unicode/choicfmt.h</a>&gt;</span>
<span class="preprocessor">   #include &lt;<a class="code" href="msgfmt_8h.html">unicode/msgfmt.h</a>&gt;</span>
<span class="preprocessor">   #include &lt;<a class="code" href="unistr_8h.html">unicode/unistr.h</a>&gt;</span>
<span class="preprocessor">   #include &lt;iostream.h&gt;</span>
 
   <span class="keywordtype">int</span> main(<span class="keywordtype">int</span> argc, <span class="keywordtype">char</span> *argv[]) {
       <a class="code" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> status = <a class="code" href="utypes_8h.html#3343c1c8a8377277046774691c98d78ca43dbfc9499c5f911d04e1a0ca3bf6f9">U_ZERO_ERROR</a>;
       <span class="keywordtype">double</span> filelimits[] = {0,1,2};
       <a class="code" href="classUnicodeString.html">UnicodeString</a> filepart[] =
           {<span class="stringliteral">"are no files"</span>,<span class="stringliteral">"is one file"</span>,<span class="stringliteral">"are {0} files"</span>};
       <a class="code" href="classChoiceFormat.html">ChoiceFormat</a>* fileform = <span class="keyword">new</span> <a class="code" href="classChoiceFormat.html">ChoiceFormat</a>(filelimits, filepart, 3 );
       <a class="code" href="classFormat.html">Format</a>* testFormats[] =
           {fileform, <a class="code" href="utypes_8h.html#070d2ce7b6bb7e5c05602aa8c308d0c4">NULL</a>, <a class="code" href="classNumberFormat.html#2483fa1e87f3600395ff0c8f364f7b6f">NumberFormat::createInstance</a>(status)};
       <a class="code" href="classMessageFormat.html">MessageFormat</a> pattform(<span class="stringliteral">"There {0} on {1}"</span>, status );
       pattform.adoptFormats(testFormats, 3);
       <a class="code" href="classFormattable.html">Formattable</a> testArgs[] = {0L, <span class="stringliteral">"Disk A"</span>};
       <a class="code" href="classFieldPosition.html">FieldPosition</a> fp(0);
       <a class="code" href="classUnicodeString.html">UnicodeString</a> str;
       <span class="keywordtype">char</span> buf[256];
       <span class="keywordflow">for</span> (<a class="code" href="platform_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> i = 0; i &lt; 4; ++i) {
           <a class="code" href="classFormattable.html">Formattable</a> fInt(i);
           testArgs[0] = fInt;
           pattform.format(testArgs, 2, str, fp, status );
           str.<a class="code" href="classUnicodeString.html#1b1b2c3fee190473eecafd617d6a3c61">extract</a>(0, str.<a class="code" href="classUnicodeString.html#c4cf80391a0e523c27aacaba796aede6">length</a>(), buf, <span class="stringliteral">""</span>);
           str.<a class="code" href="classUnicodeString.html#d8fe3cabef409468a11b77111de45ebc">truncate</a>(0);
           cout &lt;&lt; <span class="stringliteral">"Output for i="</span> &lt;&lt; i &lt;&lt; <span class="stringliteral">" : "</span> &lt;&lt; buf &lt;&lt; endl;
       }
       cout &lt;&lt; endl;
       <span class="keywordflow">return</span> 0;
   }
</pre></div><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. 
<p>

<p>
Definition at line <a class="el" href="choicfmt_8h-source.html#l00259">259</a> of file <a class="el" href="choicfmt_8h-source.html">choicfmt.h</a>.<hr><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" name="9551b876e173743f214d1530368ee92d"></a><!-- doxytag: member="ChoiceFormat::ChoiceFormat" ref="9551b876e173743f214d1530368ee92d" args="(const UnicodeString &amp;pattern, UErrorCode &amp;status)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">ChoiceFormat::ChoiceFormat           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>pattern</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>status</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Construct a new <a class="el" href="classChoiceFormat.html">ChoiceFormat</a> with the limits and the corresponding formats based on the pattern. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>pattern</em>&nbsp;</td><td>Pattern used to construct object. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>status</em>&nbsp;</td><td>Output param to receive success code. If the pattern cannot be parsed, set to failure code. </td></tr>
  </table>
</dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002067">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

</div>
</div><p>
<a class="anchor" name="5f097ff199910610ab5a5eb113e034e8"></a><!-- doxytag: member="ChoiceFormat::ChoiceFormat" ref="5f097ff199910610ab5a5eb113e034e8" args="(const double *limits, const UnicodeString *formats, int32_t count)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">ChoiceFormat::ChoiceFormat           </td>
          <td>(</td>
          <td class="paramtype">const double *&nbsp;</td>
          <td class="paramname"> <em>limits</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classUnicodeString.html">UnicodeString</a> *&nbsp;</td>
          <td class="paramname"> <em>formats</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a>&nbsp;</td>
          <td class="paramname"> <em>count</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Construct a new <a class="el" href="classChoiceFormat.html">ChoiceFormat</a> with the given limits and formats. 
<p>
Copy the limits and formats instead of adopting them.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>limits</em>&nbsp;</td><td>Array of limit values. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>formats</em>&nbsp;</td><td>Array of formats. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>count</em>&nbsp;</td><td>Size of 'limits' and 'formats' arrays. </td></tr>
  </table>
</dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002068">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

</div>
</div><p>
<a class="anchor" name="491cc4d24cbd4c42acebb158b1e04204"></a><!-- doxytag: member="ChoiceFormat::ChoiceFormat" ref="491cc4d24cbd4c42acebb158b1e04204" args="(const double *limits, const UBool *closures, const UnicodeString *formats, int32_t count)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">ChoiceFormat::ChoiceFormat           </td>
          <td>(</td>
          <td class="paramtype">const double *&nbsp;</td>
          <td class="paramname"> <em>limits</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="umachine_8h.html#349ef00011f20ccd1d3b424445681aa5">UBool</a> *&nbsp;</td>
          <td class="paramname"> <em>closures</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classUnicodeString.html">UnicodeString</a> *&nbsp;</td>
          <td class="paramname"> <em>formats</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a>&nbsp;</td>
          <td class="paramname"> <em>count</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Construct a new <a class="el" href="classChoiceFormat.html">ChoiceFormat</a> with the given limits and formats. 
<p>
Copy the limits and formats (instead of adopting them). By default, each limit in the array specifies the inclusive lower bound of its range, and the exclusive upper bound of the previous range. However, if the isLimitOpen element corresponding to a limit is TRUE, then the limit is the exclusive lower bound of its range, and the inclusive upper bound of the previous range. <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>limits</em>&nbsp;</td><td>Array of limit values </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>closures</em>&nbsp;</td><td>Array of booleans specifying whether each element of 'limits' is open or closed. If FALSE, then the corresponding limit is a member of the range above it. If TRUE, then the limit belongs to the range below it. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>formats</em>&nbsp;</td><td>Array of formats </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>count</em>&nbsp;</td><td>Size of 'limits', 'closures', and 'formats' arrays </td></tr>
  </table>
</dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002069">Stable:</a></b></dt><dd>ICU 2.4 </dd></dl>

</div>
</div><p>
<a class="anchor" name="aac82d203aea4854d148eabe422a8b17"></a><!-- doxytag: member="ChoiceFormat::ChoiceFormat" ref="aac82d203aea4854d148eabe422a8b17" args="(const ChoiceFormat &amp;that)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">ChoiceFormat::ChoiceFormat           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classChoiceFormat.html">ChoiceFormat</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>that</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Copy constructor. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>that</em>&nbsp;</td><td><a class="el" href="classChoiceFormat.html">ChoiceFormat</a> object to be copied from </td></tr>
  </table>
</dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002070">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

</div>
</div><p>
<a class="anchor" name="13b14e531d655819e8f3ab2c10bf9cb5"></a><!-- doxytag: member="ChoiceFormat::~ChoiceFormat" ref="13b14e531d655819e8f3ab2c10bf9cb5" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual ChoiceFormat::~ChoiceFormat           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Destructor. 
<p>
<dl compact><dt><b><a class="el" href="stable.html#_stable002072">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

</div>
</div><p>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="2873dacc65a6fd80c8111711a6f0c3b4"></a><!-- doxytag: member="ChoiceFormat::operator=" ref="2873dacc65a6fd80c8111711a6f0c3b4" args="(const ChoiceFormat &amp;that)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const <a class="el" href="classChoiceFormat.html">ChoiceFormat</a>&amp; ChoiceFormat::operator=           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classChoiceFormat.html">ChoiceFormat</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>that</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Assignment operator. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>that</em>&nbsp;</td><td><a class="el" href="classChoiceFormat.html">ChoiceFormat</a> object to be copied </td></tr>
  </table>
</dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002071">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

</div>
</div><p>
<a class="anchor" name="3ebd2e04337baee2dbb8c7629592714d"></a><!-- doxytag: member="ChoiceFormat::clone" ref="3ebd2e04337baee2dbb8c7629592714d" args="(void) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classFormat.html">Format</a>* ChoiceFormat::clone           </td>
          <td>(</td>
          <td class="paramtype">void&nbsp;</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Clone this <a class="el" href="classFormat.html">Format</a> object polymorphically. 
<p>
The caller owns the result and should delete it when done.<p>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>a copy of this object </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002073">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

<p>
Implements <a class="el" href="classFormat.html#a636e43fefeb57ed01add9db32dd91cb">Format</a>.
</div>
</div><p>
<a class="anchor" name="68b2c94926681294a2fe0d1c7cf52975"></a><!-- doxytag: member="ChoiceFormat::operator==" ref="68b2c94926681294a2fe0d1c7cf52975" args="(const Format &amp;other) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="umachine_8h.html#349ef00011f20ccd1d3b424445681aa5">UBool</a> ChoiceFormat::operator==           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classFormat.html">Format</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>other</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Return true if the given <a class="el" href="classFormat.html">Format</a> objects are semantically equal. 
<p>
Objects of different subclasses are considered unequal.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>other</em>&nbsp;</td><td><a class="el" href="classChoiceFormat.html">ChoiceFormat</a> object to be compared </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>true if other is the same as this. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002074">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

<p>
Reimplemented from <a class="el" href="classNumberFormat.html#97f4f81efd4747024deaf88ceb4d80a3">NumberFormat</a>.
</div>
</div><p>
<a class="anchor" name="9e558988f447da3af36ef7fc8245fb55"></a><!-- doxytag: member="ChoiceFormat::applyPattern" ref="9e558988f447da3af36ef7fc8245fb55" args="(const UnicodeString &amp;pattern, UErrorCode &amp;status)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void ChoiceFormat::applyPattern           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>pattern</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>status</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Sets the pattern. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>pattern</em>&nbsp;</td><td>The pattern to be applied. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>status</em>&nbsp;</td><td>Output param set to success/failure code on exit. If the pattern is invalid, this will be set to a failure result. </td></tr>
  </table>
</dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002075">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

</div>
</div><p>
<a class="anchor" name="01a7bc685dacb242a2cc12f502a88546"></a><!-- doxytag: member="ChoiceFormat::applyPattern" ref="01a7bc685dacb242a2cc12f502a88546" args="(const UnicodeString &amp;pattern, UParseError &amp;parseError, UErrorCode &amp;status)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void ChoiceFormat::applyPattern           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>pattern</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="structUParseError.html">UParseError</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>parseError</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>status</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Sets the pattern. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>pattern</em>&nbsp;</td><td>The pattern to be applied. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>parseError</em>&nbsp;</td><td>Struct to recieve information on position of error if an error is encountered </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>status</em>&nbsp;</td><td>Output param set to success/failure code on exit. If the pattern is invalid, this will be set to a failure result. </td></tr>
  </table>
</dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002076">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

</div>
</div><p>
<a class="anchor" name="46374a45e8f9be0760de9984f93197aa"></a><!-- doxytag: member="ChoiceFormat::toPattern" ref="46374a45e8f9be0760de9984f93197aa" args="(UnicodeString &amp;pattern) const" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classUnicodeString.html">UnicodeString</a>&amp; ChoiceFormat::toPattern           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>pattern</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Gets the pattern. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>pattern</em>&nbsp;</td><td>Output param which will recieve the pattern Previous contents are deleted. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>A reference to 'pattern' </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002077">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

</div>
</div><p>
<a class="anchor" name="5b737cf15cc825a52b7ef14b77a5b2b2"></a><!-- doxytag: member="ChoiceFormat::setChoices" ref="5b737cf15cc825a52b7ef14b77a5b2b2" args="(const double *limitsToCopy, const UnicodeString *formatsToCopy, int32_t count)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void ChoiceFormat::setChoices           </td>
          <td>(</td>
          <td class="paramtype">const double *&nbsp;</td>
          <td class="paramname"> <em>limitsToCopy</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classUnicodeString.html">UnicodeString</a> *&nbsp;</td>
          <td class="paramname"> <em>formatsToCopy</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a>&nbsp;</td>
          <td class="paramname"> <em>count</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Set the choices to be used in formatting. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>limitsToCopy</em>&nbsp;</td><td>Contains the top value that you want parsed with that format,and should be in ascending sorted order. When formatting X, the choice will be the i, where limit[i] &lt;= X &lt; limit[i+1]. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>formatsToCopy</em>&nbsp;</td><td>The format strings you want to use for each limit. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>count</em>&nbsp;</td><td>The size of the above arrays. </td></tr>
  </table>
</dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002078">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

</div>
</div><p>
<a class="anchor" name="7a9bfd3b21d29c46ffce3329b2d96668"></a><!-- doxytag: member="ChoiceFormat::setChoices" ref="7a9bfd3b21d29c46ffce3329b2d96668" args="(const double *limits, const UBool *closures, const UnicodeString *formats, int32_t count)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void ChoiceFormat::setChoices           </td>
          <td>(</td>
          <td class="paramtype">const double *&nbsp;</td>
          <td class="paramname"> <em>limits</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="umachine_8h.html#349ef00011f20ccd1d3b424445681aa5">UBool</a> *&nbsp;</td>
          <td class="paramname"> <em>closures</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classUnicodeString.html">UnicodeString</a> *&nbsp;</td>
          <td class="paramname"> <em>formats</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a>&nbsp;</td>
          <td class="paramname"> <em>count</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Set the choices to be used in formatting. 
<p>
See class description for documenatation of the limits, closures, and formats arrays. <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>limits</em>&nbsp;</td><td>Array of limits </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>closures</em>&nbsp;</td><td>Array of limit booleans </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>formats</em>&nbsp;</td><td>Array of format string </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>count</em>&nbsp;</td><td>The size of the above arrays </td></tr>
  </table>
</dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002079">Stable:</a></b></dt><dd>ICU 2.4 </dd></dl>

</div>
</div><p>
<a class="anchor" name="78f83ea324ffe884a00eb700ae550cc2"></a><!-- doxytag: member="ChoiceFormat::getLimits" ref="78f83ea324ffe884a00eb700ae550cc2" args="(int32_t &amp;count) const" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual const double* ChoiceFormat::getLimits           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>count</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Get the limits passed in the constructor. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>count</em>&nbsp;</td><td>The size of the limits arrays </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>the limits. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002080">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

</div>
</div><p>
<a class="anchor" name="247a623070c20dab1b7816b70fb063a3"></a><!-- doxytag: member="ChoiceFormat::getClosures" ref="247a623070c20dab1b7816b70fb063a3" args="(int32_t &amp;count) const" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual const <a class="el" href="umachine_8h.html#349ef00011f20ccd1d3b424445681aa5">UBool</a>* ChoiceFormat::getClosures           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>count</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Get the limit booleans passed in the constructor. 
<p>
The caller must not delete the result.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>count</em>&nbsp;</td><td>The size of the arrays </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>the closures </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002081">Stable:</a></b></dt><dd>ICU 2.4 </dd></dl>

</div>
</div><p>
<a class="anchor" name="43d283a6a28349e8acb2021a93754d6d"></a><!-- doxytag: member="ChoiceFormat::getFormats" ref="43d283a6a28349e8acb2021a93754d6d" args="(int32_t &amp;count) const" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual const <a class="el" href="classUnicodeString.html">UnicodeString</a>* ChoiceFormat::getFormats           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>count</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Get the formats passed in the constructor. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>count</em>&nbsp;</td><td>The size of the arrays </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>the formats. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002082">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

</div>
</div><p>
<a class="anchor" name="3488103b67c452ace7cac7f6da452e72"></a><!-- doxytag: member="ChoiceFormat::format" ref="3488103b67c452ace7cac7f6da452e72" args="(double number, UnicodeString &amp;appendTo, FieldPosition &amp;pos) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classUnicodeString.html">UnicodeString</a>&amp; ChoiceFormat::format           </td>
          <td>(</td>
          <td class="paramtype">double&nbsp;</td>
          <td class="paramname"> <em>number</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>appendTo</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classFieldPosition.html">FieldPosition</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>pos</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
<a class="el" href="classFormat.html">Format</a> a double or long number using this object's choices. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>number</em>&nbsp;</td><td>The value to be formatted. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>appendTo</em>&nbsp;</td><td>Output parameter to receive result. Result is appended to existing contents. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>pos</em>&nbsp;</td><td>On input: an alignment field, if desired. On output: the offsets of the alignment field. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Reference to 'appendTo' parameter. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002083">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

<p>
Implements <a class="el" href="classNumberFormat.html#7078d52baaa94ddf6e0680a4bc2f542a">NumberFormat</a>.
</div>
</div><p>
<a class="anchor" name="4c31ee3278dc0afb02e83127d4677161"></a><!-- doxytag: member="ChoiceFormat::format" ref="4c31ee3278dc0afb02e83127d4677161" args="(int32_t number, UnicodeString &amp;appendTo, FieldPosition &amp;pos) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classUnicodeString.html">UnicodeString</a>&amp; ChoiceFormat::format           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a>&nbsp;</td>
          <td class="paramname"> <em>number</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>appendTo</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classFieldPosition.html">FieldPosition</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>pos</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
<a class="el" href="classFormat.html">Format</a> a int_32t number using this object's choices. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>number</em>&nbsp;</td><td>The value to be formatted. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>appendTo</em>&nbsp;</td><td>Output parameter to receive result. Result is appended to existing contents. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>pos</em>&nbsp;</td><td>On input: an alignment field, if desired. On output: the offsets of the alignment field. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Reference to 'appendTo' parameter. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002084">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

<p>
Implements <a class="el" href="classNumberFormat.html#caaca11795df052b165e82261b7825f1">NumberFormat</a>.
</div>
</div><p>
<a class="anchor" name="066409675f3c1ec30237668f7e3a80f0"></a><!-- doxytag: member="ChoiceFormat::format" ref="066409675f3c1ec30237668f7e3a80f0" args="(int64_t number, UnicodeString &amp;appendTo, FieldPosition &amp;pos) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classUnicodeString.html">UnicodeString</a>&amp; ChoiceFormat::format           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="pwin32_8h.html#dec1df1b8b51cb32b77e5b86fff46471">int64_t</a>&nbsp;</td>
          <td class="paramname"> <em>number</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>appendTo</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classFieldPosition.html">FieldPosition</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>pos</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
<a class="el" href="classFormat.html">Format</a> an int64_t number using this object's choices. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>number</em>&nbsp;</td><td>The value to be formatted. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>appendTo</em>&nbsp;</td><td>Output parameter to receive result. Result is appended to existing contents. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>pos</em>&nbsp;</td><td>On input: an alignment field, if desired. On output: the offsets of the alignment field. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Reference to 'appendTo' parameter. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002085">Stable:</a></b></dt><dd>ICU 2.8 </dd></dl>

<p>
Reimplemented from <a class="el" href="classNumberFormat.html#c64ccd4841f822f601f2533e63e0592b">NumberFormat</a>.
</div>
</div><p>
<a class="anchor" name="fd1964f35f534b3dc9aff6e13e37e6e1"></a><!-- doxytag: member="ChoiceFormat::format" ref="fd1964f35f534b3dc9aff6e13e37e6e1" args="(const Formattable *objs, int32_t cnt, UnicodeString &amp;appendTo, FieldPosition &amp;pos, UErrorCode &amp;success) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classUnicodeString.html">UnicodeString</a>&amp; ChoiceFormat::format           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classFormattable.html">Formattable</a> *&nbsp;</td>
          <td class="paramname"> <em>objs</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a>&nbsp;</td>
          <td class="paramname"> <em>cnt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>appendTo</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classFieldPosition.html">FieldPosition</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>success</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
<a class="el" href="classFormat.html">Format</a> an array of objects using this object's choices. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>objs</em>&nbsp;</td><td>The array of objects to be formatted. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>cnt</em>&nbsp;</td><td>The size of objs. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>appendTo</em>&nbsp;</td><td>Output parameter to receive result. Result is appended to existing contents. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>pos</em>&nbsp;</td><td>On input: an alignment field, if desired. On output: the offsets of the alignment field. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>success</em>&nbsp;</td><td>Output param set to success/failure code on exit. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Reference to 'appendTo' parameter. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002086">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

</div>
</div><p>
<a class="anchor" name="27f27c3d881d63998dd49f65b838a396"></a><!-- doxytag: member="ChoiceFormat::format" ref="27f27c3d881d63998dd49f65b838a396" args="(const Formattable &amp;obj, UnicodeString &amp;appendTo, FieldPosition &amp;pos, UErrorCode &amp;status) const" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classUnicodeString.html">UnicodeString</a>&amp; ChoiceFormat::format           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classFormattable.html">Formattable</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>obj</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>appendTo</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classFieldPosition.html">FieldPosition</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>status</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
<a class="el" href="classFormat.html">Format</a> an object using this object's choices. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj</em>&nbsp;</td><td>The object to be formatted. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>appendTo</em>&nbsp;</td><td>Output parameter to receive result. Result is appended to existing contents. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>pos</em>&nbsp;</td><td>On input: an alignment field, if desired. On output: the offsets of the alignment field. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>status</em>&nbsp;</td><td>Output param set to success/failure code on exit. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Reference to 'appendTo' parameter. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002087">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

<p>
Reimplemented from <a class="el" href="classNumberFormat.html#848c716acd547e14018fd6713c6c58f2">NumberFormat</a>.
</div>
</div><p>
<a class="anchor" name="1df3b8b4b32453583e6cef2aa74c5d97"></a><!-- doxytag: member="ChoiceFormat::format" ref="1df3b8b4b32453583e6cef2aa74c5d97" args="(const Formattable &amp;obj, UnicodeString &amp;appendTo, UErrorCode &amp;status) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp; ChoiceFormat::format           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classFormattable.html">Formattable</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>obj</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>appendTo</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>status</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Redeclared <a class="el" href="classNumberFormat.html">NumberFormat</a> method. 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>obj</em>&nbsp;</td><td>The object to be formatted. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>appendTo</em>&nbsp;</td><td>Output parameter to receive result. Result is appended to existing contents. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>status</em>&nbsp;</td><td>Output param set to success/failure code on exit. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Reference to 'appendTo' parameter. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002088">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

<p>
Reimplemented from <a class="el" href="classNumberFormat.html#67d754f52d336d911454e97ba32654de">NumberFormat</a>.
<p>
Definition at line <a class="el" href="choicfmt_8h-source.html#l00756">756</a> of file <a class="el" href="choicfmt_8h-source.html">choicfmt.h</a>.
<p>
References <a class="el" href="classNumberFormat.html#848c716acd547e14018fd6713c6c58f2">NumberFormat::format()</a>.
</div>
</div><p>
<a class="anchor" name="0acf5d497c09ac281b23cd77010b5eb7"></a><!-- doxytag: member="ChoiceFormat::format" ref="0acf5d497c09ac281b23cd77010b5eb7" args="(double number, UnicodeString &amp;appendTo) const" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp; ChoiceFormat::format           </td>
          <td>(</td>
          <td class="paramtype">double&nbsp;</td>
          <td class="paramname"> <em>number</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>appendTo</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Redeclared <a class="el" href="classNumberFormat.html">NumberFormat</a> method. 
<p>
<a class="el" href="classFormat.html">Format</a> a double number. These methods call the <a class="el" href="classNumberFormat.html">NumberFormat</a> pure virtual <a class="el" href="classChoiceFormat.html#3488103b67c452ace7cac7f6da452e72">format()</a> methods with the default <a class="el" href="classFieldPosition.html">FieldPosition</a>.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>number</em>&nbsp;</td><td>The value to be formatted. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>appendTo</em>&nbsp;</td><td>Output parameter to receive result. Result is appended to existing contents. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Reference to 'appendTo' parameter. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002089">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

<p>
Reimplemented from <a class="el" href="classNumberFormat.html#d76767b9eef2144246afe02e28c73644">NumberFormat</a>.
<p>
Definition at line <a class="el" href="choicfmt_8h-source.html#l00765">765</a> of file <a class="el" href="choicfmt_8h-source.html">choicfmt.h</a>.
<p>
References <a class="el" href="classNumberFormat.html#848c716acd547e14018fd6713c6c58f2">NumberFormat::format()</a>.
</div>
</div><p>
<a class="anchor" name="917173c9f9f2f0d9e5f1de1dc09b7516"></a><!-- doxytag: member="ChoiceFormat::format" ref="917173c9f9f2f0d9e5f1de1dc09b7516" args="(int32_t number, UnicodeString &amp;appendTo) const" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp; ChoiceFormat::format           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="pwin32_8h.html#b1967d8591af1a4e48c37fd2b0f184d0">int32_t</a>&nbsp;</td>
          <td class="paramname"> <em>number</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>appendTo</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Redeclared <a class="el" href="classNumberFormat.html">NumberFormat</a> method. 
<p>
<a class="el" href="classFormat.html">Format</a> a long number. These methods call the <a class="el" href="classNumberFormat.html">NumberFormat</a> pure virtual <a class="el" href="classChoiceFormat.html#3488103b67c452ace7cac7f6da452e72">format()</a> methods with the default <a class="el" href="classFieldPosition.html">FieldPosition</a>.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>number</em>&nbsp;</td><td>The value to be formatted. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>appendTo</em>&nbsp;</td><td>Output parameter to receive result. Result is appended to existing contents. </td></tr>
  </table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Reference to 'appendTo' parameter. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002090">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

<p>
Reimplemented from <a class="el" href="classNumberFormat.html#25076f2cd93aba1a2f7ab08e86a1a84b">NumberFormat</a>.
<p>
Definition at line <a class="el" href="choicfmt_8h-source.html#l00771">771</a> of file <a class="el" href="choicfmt_8h-source.html">choicfmt.h</a>.
<p>
References <a class="el" href="classNumberFormat.html#848c716acd547e14018fd6713c6c58f2">NumberFormat::format()</a>.
</div>
</div><p>
<a class="anchor" name="f39ef720dd6a46678563da4f4f185bdd"></a><!-- doxytag: member="ChoiceFormat::parse" ref="f39ef720dd6a46678563da4f4f185bdd" args="(const UnicodeString &amp;text, Formattable &amp;result, ParsePosition &amp;parsePosition) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void ChoiceFormat::parse           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>text</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classFormattable.html">Formattable</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>result</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classParsePosition.html">ParsePosition</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>parsePosition</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Return a long if possible (e.g. 
<p>
within range LONG_MAX, LONG_MAX], and with no decimals), otherwise a double. If IntegerOnly is set, will stop at a decimal point (or equivalent; e.g. for rational numbers "1 2/3", will stop after the 1). <p>
If no object can be parsed, parsePosition is unchanged, and NULL is returned.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>text</em>&nbsp;</td><td>The text to be parsed. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>result</em>&nbsp;</td><td><a class="el" href="classFormattable.html">Formattable</a> to be set to the parse result. If parse fails, return contents are undefined. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>parsePosition</em>&nbsp;</td><td>The position to start parsing at on input. On output, moved to after the last successfully parse character. On parse failure, does not change. </td></tr>
  </table>
</dl>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classNumberFormat.html#680f60d204c0d00bb06f65d7c3ea716a">NumberFormat::isParseIntegerOnly</a> </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002091">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

<p>
Implements <a class="el" href="classNumberFormat.html#b2c59c0b036a413b6735c6d50b88ae25">NumberFormat</a>.
</div>
</div><p>
<a class="anchor" name="a1d8199f4ac3743ffb19f9deec3648f9"></a><!-- doxytag: member="ChoiceFormat::parse" ref="a1d8199f4ac3743ffb19f9deec3648f9" args="(const UnicodeString &amp;text, Formattable &amp;result, UErrorCode &amp;status) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void ChoiceFormat::parse           </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classUnicodeString.html">UnicodeString</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>text</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classFormattable.html">Formattable</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>result</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="utypes_8h.html#3343c1c8a8377277046774691c98d78c">UErrorCode</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>status</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Return a long if possible (e.g. 
<p>
within range LONG_MAX, LONG_MAX], and with no decimals), otherwise a double. If IntegerOnly is set, will stop at a decimal point (or equivalent; e.g. for rational numbers "1 2/3", will stop after the 1). <p>
If no object can be parsed, parsePosition is unchanged, and NULL is returned.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>text</em>&nbsp;</td><td>The text to be parsed. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>result</em>&nbsp;</td><td><a class="el" href="classFormattable.html">Formattable</a> to be set to the parse result. If parse fails, return contents are undefined. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>status</em>&nbsp;</td><td>Output param with the formatted string. </td></tr>
  </table>
</dl>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classNumberFormat.html#680f60d204c0d00bb06f65d7c3ea716a">NumberFormat::isParseIntegerOnly</a> </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002092">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

<p>
Reimplemented from <a class="el" href="classNumberFormat.html#01ac6e0a7a47b2d8e387752d1a024b29">NumberFormat</a>.
</div>
</div><p>
<a class="anchor" name="3bb9d296446885cca90a38e477ef5527"></a><!-- doxytag: member="ChoiceFormat::getDynamicClassID" ref="3bb9d296446885cca90a38e477ef5527" args="(void) const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="utypes_8h.html#22af10545208a455a6e884008df48e9f">UClassID</a> ChoiceFormat::getDynamicClassID           </td>
          <td>(</td>
          <td class="paramtype">void&nbsp;</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Returns a unique class ID POLYMORPHICALLY. 
<p>
Pure virtual override. This method is to implement a simple version of RTTI, since not all C++ compilers support genuine RTTI. Polymorphic <a class="el" href="classChoiceFormat.html#68b2c94926681294a2fe0d1c7cf52975">operator==()</a> and <a class="el" href="classChoiceFormat.html#3ebd2e04337baee2dbb8c7629592714d">clone()</a> methods call this method.<p>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>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. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002093">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

<p>
Implements <a class="el" href="classNumberFormat.html#63c193a4db6a1552073bf069d5d31749">NumberFormat</a>.
</div>
</div><p>
<a class="anchor" name="daeccf67d5eac282b6b3c4ccf020e9b5"></a><!-- doxytag: member="ChoiceFormat::getStaticClassID" ref="daeccf67d5eac282b6b3c4ccf020e9b5" args="(void)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">static <a class="el" href="utypes_8h.html#22af10545208a455a6e884008df48e9f">UClassID</a> ChoiceFormat::getStaticClassID           </td>
          <td>(</td>
          <td class="paramtype">void&nbsp;</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"><code> [static]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Return the class ID for this class. 
<p>
This is useful only for comparing to a return value from <a class="el" href="classChoiceFormat.html#3bb9d296446885cca90a38e477ef5527">getDynamicClassID()</a>. For example: <pre>
 .       Base* polymorphic_pointer = createPolymorphicObject();
 .       if (polymorphic_pointer-&gt;<a class="el" href="classChoiceFormat.html#3bb9d296446885cca90a38e477ef5527">getDynamicClassID()</a> ==
 .           Derived::getStaticClassID()) ...
 </pre> <dl class="return" compact><dt><b>Returns:</b></dt><dd>The class ID for all objects of this class. </dd></dl>
<dl compact><dt><b><a class="el" href="stable.html#_stable002094">Stable:</a></b></dt><dd>ICU 2.0 </dd></dl>

<p>
Reimplemented from <a class="el" href="classNumberFormat.html#cfeb8972959e9383b026761d0e9e1e5e">NumberFormat</a>.
</div>
</div><p>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="choicfmt_8h-source.html">choicfmt.h</a></ul>
<hr size="1"><address style="align: right;"><small>Generated on Fri Sep 14 12:59:38 2007 for ICU 3.8 by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.1 </small></address>
</body>
</html>