Most of the specification details can be gleaned by studying the code
and comments in the starter code provided.
In particular, there
is an interface called ISpellChecker. You must write a Java
class class SpellChecker which implements this interface (in the
technical sense, using the implements keyword). There is also
an IDocument interface. You must implement this in a class called
MyDocument. You will find other required code mentioned in the files and
elsewhere in this write-up.
Pay special attention to the comments in the starter code. It has much
important information which is not duplicated elsewhere.
You must use the
exact names for classes and methods as specified here and in those
files. You cannot declare a constructor except the one mentioned in
the interface comments. You cannot create additional .java files.
You may not modify any interfaces in this other assignments (you can't turn in
modified versions). None
of your methods should require any user input of any kind, or any input file
(this will change in later versions of the program).
You can have additional helper methods as needed; ordinarily these should be
private. You can define
additional classes but only if they are internal to the specified .java
files.
Note that the code files are in packages. You must preserve this package structure. Sometimes IDEs (like Eclipse or DrJava) will helpfully strip out or modify the package statements. Don't let this happen! If you don't have the right package structure, your .java files won't compile when you try to turn them in.
Do not use any graphics for this project.
For this and any other assignment in CSE373, you are free to use any standard Java library class, and to use any method of those classes (unless there is some explicit instruction to the contrary). You should not use any library, class, or code aside from this (for example, something you found on the Internet or written by someone outside the class).
For this particular assignment, each student should work alone. In some
future projects we may pair you up to work together.
You may have used JUnit in the past. Although this assignment involves
writing a test method, you won't use JUnit for it (we will in a later
assignment). Instead, expand and improve the classes TestSpeller and
TestDocument. In particular, make the main method of TestSpeller as
complete and thorough test of the Speller as possible. It should be able
to detect if there is any error in any implementation of ISpellChecker,
not just yours. TestDocument should also be expanded, but it won't be
weighted as much in the grading.