public int nextToken () throws IOException

Parses the next token from the input stream of this tokenizer. The type of the next token is returned in the ttype field. Additional information about the token may be in the nval field or the sval field of this tokenizer.

Typical clients of this class first set up the syntax tables and then sit in a loop calling nextToken to parse successive tokens until TT_EOF is returned.

Returns:  the value of the ttype field.

Exceptions:
IOException    if an I/O error occurs.

See also:
java.io.StreamTokenizer.nval, java.io.StreamTokenizer.sval, java.io.StreamTokenizer.ttype