Skip to content

Java classes that can be used to convert numbers into words in different languages

Notifications You must be signed in to change notification settings

aatasiei/number2words

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

55 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

number2words

Java classes that can be used to convert numbers into words in different languages

usage

import com.mambu.number2words.api.NumberTranscriber;
import com.mambu.number2words.api.factories.NumberTranscriberFactory;

NumberTranscriber transcriber = NumberTranscriberFactory.newTranscriber(Locale.ENGLISH);

transcriber.toWords(new BigDecimal("1234"));    // returns "one thousand two hundred thirty four" 
transcriber.toWords(new BigDecimal("1234.12")); // returns "one thousand two hundred thirty four **and** twelve"

###Supported languages:

Locale Language Notes
Locale.ENGLISH English Short scale. Values over 10^12 overflow.
Locale.SIMPLIFIED_CHINESE Simplified Chinese Uses financial numerals. Values over 10^12 overflow.
Locale.forLanguageTag("es") Spanish Values over 10^12 overflow.

About

Java classes that can be used to convert numbers into words in different languages

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages