diff --git a/CMakeLists.txt b/CMakeLists.txt index 7eaa90576..500218b7b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -175,6 +175,7 @@ set(ES_HEADERS ${CMAKE_CURRENT_SOURCE_DIR}/src/components/GuiInputConfig.h ${CMAKE_CURRENT_SOURCE_DIR}/src/components/GuiMenu.h ${CMAKE_CURRENT_SOURCE_DIR}/src/components/GuiSettingsMenu.h + ${CMAKE_CURRENT_SOURCE_DIR}/src/scrapers/GamesDBScraper.h ${CMAKE_CURRENT_SOURCE_DIR}/src/pugiXML/pugiconfig.hpp ${CMAKE_CURRENT_SOURCE_DIR}/src/pugiXML/pugixml.hpp ${CMAKE_CURRENT_SOURCE_DIR}/src/resources/ResourceManager.h @@ -223,6 +224,7 @@ set(ES_SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/src/components/GuiInputConfig.cpp ${CMAKE_CURRENT_SOURCE_DIR}/src/components/GuiMenu.cpp ${CMAKE_CURRENT_SOURCE_DIR}/src/components/GuiSettingsMenu.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/src/scrapers/GamesDBScraper.cpp ${CMAKE_CURRENT_SOURCE_DIR}/src/pugiXML/pugixml.cpp ${CMAKE_CURRENT_SOURCE_DIR}/src/resources/ResourceManager.cpp ${CMAKE_CURRENT_SOURCE_DIR}/src/resources/TextureResource.cpp diff --git a/src/scrapers/GamesDBScraper.cpp b/src/scrapers/GamesDBScraper.cpp new file mode 100644 index 000000000..db9811420 --- /dev/null +++ b/src/scrapers/GamesDBScraper.cpp @@ -0,0 +1,9 @@ +#include "GamesDBScraper.h" + +std::vector GamesDBScraper::getResults(ScraperSearchParams params) +{ + std::vector results; + + return results; +} + diff --git a/src/scrapers/GamesDBScraper.h b/src/scrapers/GamesDBScraper.h new file mode 100644 index 000000000..18032a3f8 --- /dev/null +++ b/src/scrapers/GamesDBScraper.h @@ -0,0 +1,10 @@ +#pragma once + +#include "Scraper.h" + +class GamesDBScraper : public IScraper +{ +public: + std::vector getResults(ScraperSearchParams params) override; +}; + diff --git a/src/scrapers/Scraper.h b/src/scrapers/Scraper.h new file mode 100644 index 000000000..7b9f92c6c --- /dev/null +++ b/src/scrapers/Scraper.h @@ -0,0 +1,23 @@ +#pragma once + +#include "../MetaData.h" +#include "../SystemData.h" +#include "../GameData.h" +#include + +struct ScraperSearchParams +{ + SystemData* sys; + GameData* game; + + std::string nameOverride; + bool async; +}; + +class IScraper +{ +public: + //Get a list of potential results. + virtual std::vector getResults(ScraperSearchParams params) = 0; +}; +