Home | History | Annotate | Download | only in unicode

Lines Matching full:code

45  * and string names for those ranges. A <code>ChoiceFormat</code> splits
46 * the real number line <code>-Inf</code> to <code>+Inf</code> into two
48 * string. <code>ChoiceFormat</code> is generally used in a
49 * <code>MessageFormat</code> for displaying grammatically correct
52 * <p>There are two methods of defining a <code>ChoiceFormat</code>; both
56 * <code>ChoiceFormat</code>.</p>
61 * <code>ChoiceFormat</code> is with a pattern. Here is an example of a
62 * <code>ChoiceFormat</code> pattern:</p>
78 * default <code>NumberFormat</code> for the US locale. It gives the
86 * characters enclosed in single quotes (<code>'The #
87 * sign'</code>). Single quotes themselves are indicated by two single
88 * quotes in a row (<code>'o''clock'</code>).</p>
98 * closure is <code>FALSE</code>.</li>
104 * <code>TRUE</code>.
111 * <p>A <code>ChoiceFormat</code> defining <code>n</code> intervals
112 * (<code>n</code> &gt;= 2) is specified by three arrays of
113 * <code>n</code> items:
116 * <li><code>double limits[]</code> gives the start of each
118 * which may be <code>NaN</code>.</li>
119 * <li><code>UBool closures[]</code> determines whether each limit
121 * above it. If <code>closures[i]</code> is <code>FALSE</code>, then
122 * <code>limits[i]</code> is a member of interval
123 * <code>i</code>. Otherwise it is a member of interval
124 * <code>i+1</code>. If no closures array is specified, this is
125 * equivalent to having all closures be <code>FALSE</code>. Closures
127 * <li><code>UnicodeString formats[]</code> gives the string label
134 * string. <code>ChoiceFormat</code> accomplishes this by mapping the
136 * <code>X</code> and and index value <code>j</code> in the range
137 * <code>0..n-1</code>, where <code>n</code> is the number of ranges:</p>
139 * \htmlonly<blockquote>\endhtmlonly<code>X</code> matches <code>j</code> if and only if
140 * <code>limit[j] &lt;= X &lt; limit[j+1]</code>
143 * <p>(This assumes that all closures are <code>FALSE</code>. If some
144 * closures are <code>TRUE</code> then the relations must be changed to
145 * <code>&lt;=</code> or <code>&lt;</code> as appropriate.) If there is
148 * an interval <code>j</code>, the string <code>formats[j]</code> is
152 * number. <code>ChoiceFormat</code> finds the element
153 * <code>formats[j]</code> equal to the string, and returns
154 * <code>limits[j]</code> as the parsed value.</p>
159 * example, in the pattern \htmlonly&quot;<code>1.0#a|2.0#b</code>&quot;\endhtmlonly, the
164 * formatting. In this example, <code>parse(&quot;a&quot;)</code> returns
168 * covered. A <code>ChoiceFormat</code> maps <em>all</em> possible
171 * <p>The non-number <code>NaN</code> is mapped to interval zero during
177 * <code>1..7</code> to the English day of the week abbreviations
178 * <code>Sun..Sat</code>. No closures array is given; this is the same as
179 * specifying all closures to be <code>FALSE</code>.</p>
194 * \code
218 * <p>Here is a more complex example using a <code>ChoiceFormat</code>
220 * <code>MessageFormat</code>.</p>
222 * \code
256 * subclasses, such code will not necessarily work and will not be
266 * @param status Output param to receive success code. If the
267 * pattern cannot be parsed, set to failure code.
354 * @param status Output param set to success/failure code on
367 * @param status Output param set to success/failure code on
496 * @param success Output param set to success/failure code on
515 * @param status Output param set to success/failure code on
531 * @param status Output param set to success/failure code on
669 * @param status Output param to receive success code. If the
670 * pattern cannot be parsed, set to failure code.