Numberings for selected languages
Numberer
implementations are available for several selected European languages, and
you can use these as a prototype to write your own.
In Saxon-PE/EE these numberers are used for the given languages only if the JAR file containing the ICU libraries is not available on the classpath. (This is a transitional arrangement for Saxon 9.6, to ease transition to ICU. This mechanism will probably be dropped in a later release.) These numberers are not built in with Saxon-HE, but are available as open source code, and it is possible to configure them by writing a subclass of LocalizerFactory and registering it with the Configuration.
The languages available are:
code |
Language |
Class |
da |
Danish |
|
de |
German |
|
en |
English |
|
fr |
French |
|
fr-BE |
French (Belgium) |
|
it |
Italian |
|
nl |
Dutch |
|
nl-BE |
Flemish (Belgium) |
|
sv |
Swedish |
|
For English, the language codes en-x-hyphen
and en-x-nohyphen
can be used to control whether numbers in the range 21 to 99
are spelled out with hyphen or space as a separator ("thirty-one" versus "thirty one"). By default, a hyphen is used for ordinal numbers, while a space
is used for cardinal numbers.