#pragma once #include "ServerApplicationDefaultSettings.h" #include "ServerApplicationsTree.h" #include "Module.h" #include #include namespace HttpServer { class ConfigParser { private: bool includeConfigFile(const std::string &, std::string &, const size_t); bool addApplication( const std::unordered_map &, const ServerApplicationDefaultSettings &, std::vector &modules, ServerApplicationsTree &apps_tree ); bool parseMimes(const std::string &fileName, std::unordered_map &mimes_types); public: bool loadConfig( const std::string &conf, std::unordered_map &settings, std::unordered_map &mimes_types, std::vector &modules, ServerApplicationsTree &apps_tree ); }; };