//Editor-Info: -*- C++ -*-
//
//Subject: TOVE project / pf
//
//File: fileparser.h
//
//Version: $Revision: 1.2 $
//
//State: $State: Exp $
//
//Date: $Date: 1998/10/05 07:24:27 $
//
//Organisation:
//      Helsinki University of Technology
//      Laboratory of Telecommunications Software and Multimedia
//
//Author:
//      Juhana Räsänen
//
//Description:
//      Class to provide an abstraction to a file that consists of
//      whitespace-separated keyword-parameter pairs, one pair per
//      line, comments (lines starting with '#') allowed.
//
//Copyright:
//      Copyright 1999 Helsinki University of Technology
//      ALL RIGHTS RESERVED BETWEEN JANUARY 1996 AND JUNE 1999.
//
//Licence:
//
//
//History: 
//
//

#ifndef __PF_PARSER_H__
#define __PF_PARSER_H__

#include <stdio.h>
#include <typeinfo>

class pfParser
{
    public:
        explicit pfParser(const char *filename_);
        virtual ~pfParser(void);

        int nextKeyword(char *keyword_,
                        char *parameter_,
                        const char *findThis_ = 0);
        void rewind(void);

    private:
        void eatWhite(void);
        char *findNextWord(char *buffer_);
        FILE *_inputFile;
};

#endif  // __PF_PARSER_H__ 

