String and Stream Tokenizer

String tokenizer contains useful methods that can be used to isolate the tokens. StringTokenizer provides two methods that are very effective for the processing string. These methods are countToken and nextToken. To use methods of the class StringTokenizer, user needs to create object of this class. This class provides two constructors to create its object. StringTokenizer can be used to process input from a file line by line. While reading an input string supplied by a user, it is analysed token-by-token.  To isolate the tokens StringTokenizer class is used, which is found in the package java dot util. Streamtokenizer is a predefined class which parses the input stream into the tokens. This class is contained in java.util package. StreamTokenizer class also provides four static int variables to check the token type.

To Access the full content, Please Purchase