FileDriver

#ifndef FILEDRIVER_H

#define FILEDRIVER_H

#include "Bar.h"

#include "DriverException.h"

class FileDriver

{

public:

    FileDriver();

    virtual ~FileDriver();

    virtual bool open(const std::string& filename) = 0;

    //! Close file.

    virtual void close(void) = 0;

    //! Read the next EOD record from the file.

    virtual bool next(Bar& record) throw(DriverException) = 0;

    //! EOF check.

    virtual bool eof(void) = 0;

protected:

private:

};

#endif // FILEDRIVER_H

#include "FileDriver.h"

FileDriver::FileDriver()

{

    //ctor

}

FileDriver::~FileDriver()

{

    //dtor

}