ES-DE/src/GameData.h

46 lines
925 B
C
Raw Normal View History

#ifndef _GAMEDATA_H_
#define _GAMEDATA_H_
#include <string>
#include "FileData.h"
#include "SystemData.h"
2013-08-14 12:16:49 +00:00
#include "MetaData.h"
//This class holds information about a game: at the least, its name, system, and path. Additional information is optional and read by other classes.
class GameData : public FileData
{
public:
2013-08-14 12:16:49 +00:00
GameData(SystemData* system, std::string path);
2013-08-14 12:16:49 +00:00
const std::string& getName() const override;
const std::string& getPath() const override;
void incTimesPlayed();
void lastPlayedNow();
std::string getBashPath() const;
std::string getBaseName() const;
2013-08-14 12:16:49 +00:00
bool isFolder() const override;
MetaDataList* metadata();
private:
SystemData* mSystem;
2013-08-14 12:16:49 +00:00
const std::string mPath;
const std::string mBaseName;
//extra data
2013-08-14 12:16:49 +00:00
/*std::string mDescription;
std::string mImagePath;
float mRating;
float mUserRating;
size_t mTimesPlayed;
2013-08-14 12:16:49 +00:00
std::time_t mLastPlayed;*/
MetaDataList mMetaData;
};
#endif