Joshua Levy's Open Source Java Implementation
of
Daitch Mokotoff Soundex

Version 0.1 (early beta test) This is a very early release, please tell me about any problems that you find, any documentation that needs improvement, and so on. Your input will make this software better. Readme and License Zip File Javadocs

This software implements the Daitch Mokotoff Soundex algorithm. You can use it as a command line program, or a java class, and encorporate it into your own Java software.

More information on this soundex system can be found on these web sites:

To use it as a program, do this:

   java DMSoundex --version  (or -v or -V) prints out a version number
   java DMSoundex --help     (or -h or -H) prints out this help information
   java DMSoundex            Self test: prints out names and codes
   java DMSoundex <name>     Prints the DM soundex(es) for this name
So if you enter java DMSoundex levy you will get 870000, and so on. If you do not supply a name, then DMSoundex will run it's self test suite, printing out a list of names and their Daitch Mokotoff codes.

To use this class from java code, you need to create a DMSoundex object, and then call one of three methods, as shown below:

    String r1 ;
    String r2 ;
    String ra[] ;
    DMSoundex dms = new DMSoundex() ;
    r1 = dms.soundexes("daich") ;
    r2 = dms.sencode("daich") ;
    ra = dms.soundex("daich") ;
    r1 will now contain: "350000 340000"
    r2 will contain "350000"
    ra will be an array with two entries, "350000" and "340000"