Package java.util
Class StringTokenizer

Public Method nextToken

String nextToken()

Throws:

String nextToken(String delims)

_INSERT_METHOD_SIGNATURE_HERE_

Description:

nextToken() method:

Returns the next token from this string tokenizer.

nextToken(String delims) method:

Returns the next token in this string tokenizer's string. First, the set of characters considered to be delimiters by this StringTokenizer object is changed to be the characters in the sting delims. Then the next token in the string after the current position is returned. The current position is advanced beyond the recognized token. The new delimiter set remains the default after this call.

Example

   StringTokenizer strTok = new StringTokenizer("Hello World\rThis is a\t\ttest string!\n");
   while (strTok.hasMoreTokens())
      Logger.log(strTok.nextToken());

The different elements are written to the logger as long as further tokens are available.