Class cs1.SafeInput

java.lang.Object
|
+----cs1.SafeInput

public class SafeInput

extends Object

Provides line buffered input that can be used either interactively
or from a file. In interactive mode (using a non-null prompt file),
one item is read per line. In "batch" mode (prompt = null), lines
may contain several elements. Note that getLine
retrieves the rest of the current line. In non-interactive mode,
tokens will be skipped to try to find one of the desired kind. For
example if you getInt() when the next input token is not a legal int,
tokens will be skipped looking for an int. Failure will come at the
end of the file, of course.