Class StreamTokenizerUtils

    • Constructor Detail

      • StreamTokenizerUtils

        public StreamTokenizerUtils()
    • Method Detail

      • getFirstToken

        public static void getFirstToken​(StreamTokenizer tokenizer)
                                  throws IOException
        Gets token, skipping empty lines.
        Parameters:
        tokenizer - the stream tokenizer
        Throws:
        IOException - if reading the next token fails
      • getToken

        public static void getToken​(StreamTokenizer tokenizer)
                             throws IOException
        Gets token.
        Parameters:
        tokenizer - the stream tokenizer
        Throws:
        IOException - if reading the next token fails
      • errms

        public static void errms​(StreamTokenizer tokenizer,
                                 String theMsg)
                          throws IOException
        Throws error message with line number and last token read.
        Parameters:
        theMsg - the error message to be thrown
        tokenizer - the stream tokenizer
        Throws:
        IOException - containing the error message