Source

pyGAP / game / inc / io / settings.h

Full commit
#ifndef _IO_SETTINGS_H_
#define _IO_SETTINGS_H_

#include <libconfig.h>


namespace io {


class Settings
{
public:
    Settings();
    virtual ~Settings();

    int set_file(const char* filename) { filename_ = filename; return 0; }
    virtual int read() = 0;
    virtual int write() = 0;

protected:
    config_setting_t* get_member(config_setting_t* root, const char* name, int type);

    config_t config_;
    config_setting_t* root_;
    const char* filename_;
};


} // namespace io


#endif // _IO_SETTINGS_H_