•
while (
wordIterator.hasNext() ) {
• word = (String)wordIterator.next();
• definition = this.getEntry( word );
• str += word +
":\n" +
definition.toString()
+ "\n";
•
}
•use the key to look up a Definition
•send the Definition a toString
message
•add two lines to the String str
we are building to represent
the whole Dictionary