aspose file tools*
The moose likes Java in General and the fly likes How to implement spell checker in Java Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Bookmark "How to implement spell checker in Java" Watch "How to implement spell checker in Java" New topic
Author

How to implement spell checker in Java

Nitin Nigam
Ranch Hand

Joined: Jul 03, 2006
Posts: 129
Can anybody tell me how can we implement a spell checker(English) in my application.
Requirement:
I will pass a string, and it should tell me if it is a valid English dictionary word.

For this i need a English dictionary loaded in my JVM. May be in form of some jar.

There is a Dictionary implementation of Collection that implements HashMap. But it has to be populated before i can use it.

Please help!!!


Nothing is impossible; for those who doesnt have to do it themselves.
myjotting.blogspot.com
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

Hmm. While the JDK does contain a Dictionary interface I think you've missunderstood its intention. You should note that the JavaDocs do say this about it:

This class is obsolete. New implementations should implement the Map interface, rather than extending this class.

There are lots of Spell Checker APIs out there. Try googling for "java spell checker" and you should find plenty to get you going.

All that aside, this is not really an advanced question. Moving...
[ January 17, 2007: Message edited by: Paul Sturrock ]

JavaRanch FAQ HowToAskQuestionsOnJavaRanch
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to implement spell checker in Java