/pe1/src/cs276/pe1/spell/SpellingCorrector.java
Java | 24 lines | 5 code | 3 blank | 16 comment | 0 complexity | a8242df47390e09277b61d292d221098 MD5 | raw file
- package cs276.pe1.spell;
- import java.util.List;
- /**
- * Basic interface for the spelling corrector.
- *
- * @author dramage
- */
- public interface SpellingCorrector {
- /**
- * Returns list of possible spelling corrections for a given
- * (possibly misspelled) word. The length of the returned list
- * is up to the implementer, but enough high-scoring candidates
- * should be included so that the best corrected spelling is
- * present (high) in the list.
- *
- * @param word A single word whose spelling is to be checked.
- * @return A list of possible corrections, with better corrections
- * ordered first.
- */
- public List<String> corrections(String word);
- }