Meta tags:
description= ICU is a mature, widely used set of C/C++ and Java libraries providing Unicode and Globalization support for software applications. The ICU User Guide provides documentation on how to use ICU.;
Headings (most frequently used words):
rulebasednumberformat, examples, contents, annotated, example,
Text of the page (most frequently used words):
the (59), and (24), icu (24), for (20), rule (20), 000 (17), this (14), rules (12), #examples (11), range (11), rulebasednumberformat (9), documentation (8), value (8), using (8), formatting (8), setup (8), icu4c (8), data (8), use (7), with (7), number (6), ranges (6), previous (6), recurse (6), one (6), point (6), java (6), docs (5), unicode (5), ruleset (5), starts (5), these (5), new (5), numbers (5), string (5), example (5), code (5), icu4j (5), github (4), api (4), all (4), pattern (4), means (4), text (4), decimal (4), format (4), start (4), 100 (4), emit (4), two (4), time (4), page (3), can (3), are (3), negative (3), fractional (3), current (3), similar (3), 1000 (3), ten (3), default (3), part (3), each (3), zero (3), integer (3), minus (3), following (3), how (3), search (3), updating (3), cldr (3), integration (3), release (3), apis (3), collation (3), faq (3), date (3), site (2), uses (2), theme (2), jekyll (2), just (2), more (2), found (2), source (2), rulesets (2), invoked (2), first (2), applying (2), then (2), that (2), again (2), syntax (2), applies (2), 10e15 (2), unmodified (2), describes (2), they (2), except (2), output (2), space (2), order (2), when (2), not (2), integral (2), single (2), nine (2), digits (2), consist (2), lists (2), most (2), colon (2), provides (2), information (2), about (2), work (2), three (2), four (2), formats (2), annotated (2), home (2), git (2), profiling (2), developers (2), contributors (2), user (2), guide (2), break (2), synchronization (2), version (2), update (2), measureunit (2), publish (2), tests (2), copy (2), build (2), custom (2), tries (2), normalization (2), design (2), layout (2), calendar (2), services (2), resources (2), locale (2), conversion (2), link (2), edit, 2016, later, inc, others, license, terms, http, www, org, copyright, html, back, top, demo, finding, whose, includes, recursing, directed, complete, description, last, values, over, within, works, patterns, well, presumed, constructed, intervals, comma, delimit, thousands, note, include, commas, readability, limiting, matching, against, find, must, force, get, processing, like, 105, sets, limit, divide, divisor, which, defaults, highest, power, lower, equal, remainder, succeeding, has, corresponding, process, mode, generally, emits, absolute, unnamed, nineteen, terminated, semicolon, special, handling, non, integers, true, increasing, portion, before, any, some, additional, apply, bodies, recursion, instructions, plain, substitutions, follows, five, six, seven, eight, standard, place, notation, but, words, instead, 123, quick, idea, detail, contents, local, tooling, configs, maven, monitoring, tools, errorprone, eclipse, ant, callgrind, configuring, linux, editing, built, iterator, skipping, known, test, failures, including, standards, wip, miscellaneous, maintenance, procedure, legalities, healthy, shared, updates, announcements, milestone, tasks, developing, fuzzer, targets, continuous, coding, guidelines, reports, preparsed, ucd, ucharstrie, bytestrie, structures, cobol, from, resource, tracing, tool, paragraph, engine, ustream, ustdio, boundary, analysis, ignore, punctuation, options, details, customization, architecture, concepts, transform, tutorial, bidi, algorithm, case, mappings, transforms, trying, final, candidate, messageformat, message, messages, dates, times, formattedvalue, skeletons, rounding, modes, legacy, numberformat, universal, scale, zone, timezone, classes, localizing, locales, compression, charset, detection, converter, stringprep, regular, expressions, unicodeset, properties, utext, characteriterator, iterators, utf, chars, strings, why, service, provider, plug, ins, header, only, packaging, building, demos, glossary, info, posix, migration, basics, internationalization, contacts, mailing, downloading, copied, document, external, expand, menu, skip, main, content,
Text of the page (random words):
rulebasednumberformat examples icu documentation skip to main content link menu expand external link document search copy copied icu documentation icu documentation downloading icu icu 78 icu 77 icu 76 contacts and mailing lists icu user guide icu internationalization how to use icu unicode basics icu services icu design c posix migration release info glossary demos icu4c icu4c faq building icu4c packaging icu4c c header only apis plug ins icu4j icu4j faq icu4j locale service provider why use icu4j chars and strings utf 8 c code point iterators characteriterator utext properties unicodeset regular expressions stringprep conversion converter conversion data charset detection compression locales and resources locale examples resources localizing with icu date time calendar services calendar examples timezone classes date and time zone examples universal time scale formatting formatting numbers legacy numberformat rounding modes number skeletons formattedvalue rulebasednumberformat rulebasednumberformat examples formatting dates and times date and time formatting examples formatting messages message formatting examples messageformat 2 0 trying mf 2 0 final candidate transforms case mappings bidi algorithm normalization transform rule tutorial collation concepts architecture customization string search collation faq api details collation examples ignore punctuation options boundary analysis break rules io ustdio ustream layout engine paragraph layout icu data icu data build tool resource and data tracing use from cobol design docs custom normalization data structures bytestrie icu code point tries icu string tries ucharstrie preparsed ucd contributors ci reports coding guidelines continuous integration custom icu4c synchronization developing fuzzer targets for icu apis release milestone tasks announcements apis docs build updates copy shared tests healthy code integration tests legalities maintenance release procedure miscellaneous publish publish version 76 1 wip standards update cldr icu integration including icu4c data to icu4j updating measureunit with new cldr data updating measureunit with new cldr data unicode update version numbers skipping known test failures synchronization updating icu s built in break iterator rules user guide editing git and github for icu developers setup for contributors c setup c setup on linux configuring vs code for icu4c profiling icu4c with callgrind java setup ant setup for java eclipse setup for java developers errorprone for java java profiling and monitoring tools maven setup for java source code setup local tooling configs for git and github this site uses just the docs a documentation theme for jekyll search icu documentation api docs icu on github icu home page unicode home page formatting formatting numbers rulebasednumberformat examples rulebasednumberformat examples contents annotated rulebasednumberformat example annotated rulebasednumberformat example the following example provides a quick idea of how the rules work the rulebasednumberformat api documentation describes the rule syntax in more detail this ruleset formats a number using standard decimal place value notation but using words instead of digits e g 123 4 formats as one two three point four x minus n x x point n zero one two three four five six n seven eight nine n 10 n 100 n 1000 n 1 000 000 n 1 000 000 000 n 1 000 000 000 000 n 1 000 000 000 000 000 0 n in this example the rules consist of one unnamed ruleset it lists nineteen rules each terminated by a semicolon it starts with two special rules for handling negative numbers and non integers this is true of most rulesets following are rules for increasing integer ranges up to 10e15 the portion of the rule before a colon if any provides information about the range and some additional information about how to apply the rule most rule bodies following the colon consist of recursion instructions and or plain text substitutions the rules in this example work as follows x minus if the number is negative output the string minus and recurse using the absolute value x x point if the number is not an integer recurse using the integral part emit the string point and process the ruleset in fractional mode for the fractional part generally this emits single digits zero one nine each of these ten rules applies to a range by default the first range starts at zero and succeeding ranges start at the previous start 1 these ranges all default so each of these ten rules has a range of a single integer 0 to 9 when the current value is in one of these ranges the rules emit the corresponding text e g one two and so on 10 this starts a new range at 10 not default and sets the limit of the range for the previous rule divide the number by the divisor which defaults to the highest power of 10 lower or equal to range start value e g 10 recurse using the integral part emit the string space then recurse using the remainder 100 this starts a new range at 100 again limiting the previous rule s range it is similar to the previous rule except for the use of means to recurse by matching the value against all the ranges to find the rule means to recurse using the previous rule we must force the previous rule in order to get the rule for ten invoked in order to emit 0 when processing numbers like 105 1000 1 000 000 these start new ranges at intervals of 1000 they are all similar to the rule for 100 except they output comma space to delimit thousands note that the range value can include commas for readability 1 000 0 this last rule in the ruleset applies to all values at or over 10e15 the pattern means to use the current unmodified value and text within in the pattern this works for and similar patterns as well describes the ruleset or decimal format to use if this text starts with 0 or it is presumed to be a decimal format pattern so this rule means to format the unmodified number using a decimal format constructed with the pattern 0 rulesets are invoked by first applying negative and fractional rules then by finding the rule whose range includes the current value and applying that rule recursing as directed by the rule again a complete description of the rule syntax can be found in the api documentation more rule examples can be found in the rulebasednumberformat demo source back to top 2016 and later unicode inc and others license terms of use http www unicode org copyright html edit this page on github this site uses just the docs a documentation theme for jekyll
|